From dc2c1410831e4d610453a712347e1b4dd5a1ebc7 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Wed, 20 Apr 2022 14:26:17 -0500 Subject: [PATCH] Change multiline chain style --- .rubocop.yml | 3 +++ sgx_jmp.rb | 3 +-- test/test_electrum.rb | 12 ++++-------- test/test_tel_selections.rb | 6 ++---- 4 files changed, 10 insertions(+), 14 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index d0b95af..0da0a6e 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -64,6 +64,9 @@ Layout/AccessModifierIndentation: Layout/FirstParameterIndentation: EnforcedStyle: consistent +Layout/MultilineMethodCallIndentation: + EnforcedStyle: indented + Style/AccessModifierDeclarations: Enabled: false diff --git a/sgx_jmp.rb b/sgx_jmp.rb index 5fc7c42..ad80b29 100644 --- a/sgx_jmp.rb +++ b/sgx_jmp.rb @@ -46,8 +46,7 @@ module SentryOugai end LOG.extend SentryOugai -CONFIG = - Dhall::Coder +CONFIG = Dhall::Coder .new(safe: Dhall::Coder::JSON_LIKE + [Symbol, Proc]) .load( "(#{ARGV[0]}) : #{__dir__}/config-schema.dhall", diff --git a/test/test_electrum.rb b/test/test_electrum.rb index 316c580..28290c6 100644 --- a/test/test_electrum.rb +++ b/test/test_electrum.rb @@ -28,8 +28,7 @@ class ElectrumTest < Minitest::Test property(:getaddresshistory) { string(:alnum) } em :test_getaddresshistory def getaddresshistory(address) - req = - stub_rpc("getaddresshistory", address: address) + req = stub_rpc("getaddresshistory", address: address) .to_return(body: { result: "result" }.to_json) assert_equal "result", @electrum.getaddresshistory(address).sync assert_requested(req) @@ -38,8 +37,7 @@ class ElectrumTest < Minitest::Test property(:get_tx_status) { string(:alnum) } em :test_get_tx_status def get_tx_status(tx_hash) - req = - stub_rpc("get_tx_status", txid: tx_hash) + req = stub_rpc("get_tx_status", txid: tx_hash) .to_return(body: { result: "result" }.to_json) assert_equal "result", @electrum.get_tx_status(tx_hash).sync assert_requested(req) @@ -48,11 +46,9 @@ class ElectrumTest < Minitest::Test property(:gettransaction) { [string(:alnum), string(:xdigit)] } em :test_gettransaction def gettransaction(tx_hash, dummy_tx) - req1 = - stub_rpc("gettransaction", txid: tx_hash) + req1 = stub_rpc("gettransaction", txid: tx_hash) .to_return(body: { result: dummy_tx }.to_json) - req2 = - stub_rpc("deserialize", [dummy_tx]) + req2 = stub_rpc("deserialize", [dummy_tx]) .to_return(body: { result: { outputs: [] } }.to_json) assert_kind_of Electrum::Transaction, @electrum.gettransaction(tx_hash).sync assert_requested(req1) diff --git a/test/test_tel_selections.rb b/test/test_tel_selections.rb index 1285fd0..5bc15b7 100644 --- a/test/test_tel_selections.rb +++ b/test/test_tel_selections.rb @@ -26,8 +26,7 @@ class TelSelectionsTest < Minitest::Test def test_for_no_rsm form = Blather::Stanza::X.new form.fields = [{ var: "q", value: "226" }] - iris_query = - TelSelections::ChooseTel::AvailableNumber + iris_query = TelSelections::ChooseTel::AvailableNumber .for(form) .instance_variable_get(:@iris_query) assert_equal( @@ -44,8 +43,7 @@ class TelSelectionsTest < Minitest::Test max 500 end end - iris_query = - TelSelections::ChooseTel::AvailableNumber + iris_query = TelSelections::ChooseTel::AvailableNumber .for(form) .instance_variable_get(:@iris_query) assert_equal( -- 2.38.5