Skip to content

Commit

Permalink
Update gems (#466)
Browse files Browse the repository at this point in the history
  • Loading branch information
miry committed Jan 20, 2023
1 parent 1dab1fe commit 293a390
Show file tree
Hide file tree
Showing 11 changed files with 42 additions and 36 deletions.
30 changes: 15 additions & 15 deletions Gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions gemfiles/rails.gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions gemfiles/redis_4.gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions gemfiles/redis_5.gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions gemfiles/redis_client.gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions test/adapters/grpc_test.rb
Expand Up @@ -70,6 +70,7 @@ def test_rpc_server_with_operation

def test_unavailable_server_opens_the_circuit
GRPC::ActiveCall.any_instance.stubs(:request_response).raises(::GRPC::Unavailable)

ERROR_THRESHOLD.times do
assert_raises(::GRPC::Unavailable) do
@stub.an_rpc(EchoMsg.new)
Expand Down Expand Up @@ -204,6 +205,7 @@ def test_bulkheads_tickets_are_working
stub1 = build_insecure_stub(EchoStub)
stub1.semian_resource.acquire do
stub2 = build_insecure_stub(EchoStub, host: "0.0.0.1")

stub2.semian_resource.acquire do
assert_raises(GRPC::ResourceBusyError) do
stub2.an_rpc(EchoMsg.new)
Expand Down
1 change: 1 addition & 0 deletions test/adapters/mysql2_test.rb
Expand Up @@ -54,6 +54,7 @@ def test_connection_errors_open_the_circuit

def test_query_errors_does_not_open_the_circuit
client = connect_to_mysql!

(ERROR_THRESHOLD * 2).times do
assert_raises(::Mysql2::Error) do
client.query("ERROR!")
Expand Down
3 changes: 3 additions & 0 deletions test/adapters/net_http_test.rb
Expand Up @@ -111,6 +111,7 @@ def test_bulkheads_tickets_are_working
http_1 = Net::HTTP.new(SemianConfig["toxiproxy_upstream_host"], SemianConfig["http_toxiproxy_port"])
http_1.semian_resource.acquire do
http_2 = Net::HTTP.new(SemianConfig["toxiproxy_upstream_host"], SemianConfig["http_toxiproxy_port"])

http_2.semian_resource.acquire do
assert_raises(Net::ResourceBusyError) do
Net::HTTP.get(URI("http://#{SemianConfig["toxiproxy_upstream_host"]}:#{SemianConfig["http_toxiproxy_port"]}/"))
Expand Down Expand Up @@ -232,6 +233,7 @@ def test_custom_raw_semian_options_can_only_assign_once
semian_configuration_proc = proc do |host, port|
DEFAULT_SEMIAN_OPTIONS.merge(name: "#{host}_#{port}")
end

with_semian_configuration(semian_configuration_proc) do
assert_raises(Semian::NetHTTP::SemianConfigurationChangedError) do
Semian::NetHTTP.semian_configuration = semian_configuration_proc
Expand Down Expand Up @@ -320,6 +322,7 @@ def test_use_custom_configuration_to_combine_endpoints_into_one_resource
with_server do
open_circuit!
end

with_server(
ports: [SemianConfig["http_port_service_a"], SemianConfig["http_port_service_b"]],
reset_semian_state: false,
Expand Down
1 change: 1 addition & 0 deletions test/adapters/redis_client_test.rb
Expand Up @@ -94,6 +94,7 @@ def test_connection_reset_does_not_open_the_circuit
def test_command_errors_does_not_open_the_circuit
client = connect_to_redis!
client.call("HSET", "my_hash", "foo", "bar")

(ERROR_THRESHOLD * 2).times do
assert_raises(RedisClient::CommandError) do
client.call("GET", "my_hash")
Expand Down
1 change: 1 addition & 0 deletions test/adapters/redis_test.rb
Expand Up @@ -96,6 +96,7 @@ def test_connection_reset_does_not_open_the_circuit
def test_command_errors_does_not_open_the_circuit
client = connect_to_redis!
client.hset("my_hash", "foo", "bar")

(ERROR_THRESHOLD * 2).times do
assert_raises(Redis::CommandError) do
client.get("my_hash")
Expand Down
2 changes: 0 additions & 2 deletions test/lru_hash_test.rb
Expand Up @@ -172,8 +172,6 @@ def test_monotonically_increasing
# At this point, the table looks like: [a, c, b, d, e]
assert_equal(notification, payload[:size])
assert_equal(3, payload[:examined])
else
assert_nil(true)
end
end

Expand Down

0 comments on commit 293a390

Please sign in to comment.