مراية لـ
https://github.com/postalserver/postal.git
تم المزامنة 2025-12-01 05:43:04 +00:00
This will automatically increase the DB connection pool size if the number of threads needed in a worker is less than the maximum pool size configured.
19 أسطر
619 B
Ruby
19 أسطر
619 B
Ruby
# frozen_string_literal: true
|
|
|
|
require "rails_helper"
|
|
|
|
RSpec.describe Postal do
|
|
describe "#signer" do
|
|
it "returns a signer with the installation's signing key" do
|
|
expect(Postal.signer).to be_a(Postal::Signer)
|
|
expect(Postal.signer.private_key.to_pem).to eq OpenSSL::PKey::RSA.new(File.read(Postal::Config.postal.signing_key_path)).to_pem
|
|
end
|
|
end
|
|
|
|
describe "#change_database_connection_pool_size" do
|
|
it "changes the connection pool size" do
|
|
expect { Postal.change_database_connection_pool_size(8) }.to change { ActiveRecord::Base.connection_pool.size }.from(5).to(8)
|
|
end
|
|
end
|
|
end
|