Skip to content

Commit

Permalink
Receiving address can be also empty
Browse files Browse the repository at this point in the history
  • Loading branch information
Piotr Stachyra committed Apr 15, 2022
1 parent 14c905f commit 9d92609
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/e2e/spec/e2e_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -625,14 +625,14 @@ def mint(asset_name, quantity, policy_script, address = nil)
'operation' => {
'mint' =>
{
'receiving_address' => address,
'amount' => { 'quantity' => quantity,
'unit' => 'assets'
}
}
},
'policy_script_template' => policy_script
}
mint['operation']['mint']['receiving_address'] = address unless address == nil
mint['asset_name'] = asset_name unless asset_name == nil
mint
end
Expand Down Expand Up @@ -740,7 +740,7 @@ def get_policy_id_from_decode(tx_decoded_mint_or_burn)
# Burn all the rest:
burn = [burn(asset_name('Token1'), 500, policy_script1),
burn(asset_name('Token2'), 500, policy_script2),
burn('', 500, policy_script3)
burn(nil, 500, policy_script3)
]
tx_constructed, tx_signed, tx_submitted = construct_sign_submit(@wid,
payments = nil,
Expand Down Expand Up @@ -1205,8 +1205,9 @@ def get_policy_id_from_decode(tx_decoded_mint_or_burn)
expect(assets).to eq(assets_to_check.map{|z| {z => assets_quantity}}.to_set)

# Try to burn on target wallet and fail:
create_policy_key_if_not_exists(@target_id)
burn = [burn(assets_name, assets_quantity, policy_script)]
tx_constructed = SHELLEY.transactions.construct(@wid,
tx_constructed = SHELLEY.transactions.construct(@target_id,
payments = nil,
withdrawal = nil,
metadata = nil,
Expand Down Expand Up @@ -1397,7 +1398,6 @@ def get_policy_id_from_decode(tx_decoded_mint_or_burn)
expect(tx_constructed['code']).to eq 'output_token_bundle_size_exceeds_limit'
end
end

end

describe "E2E Shared" do
Expand Down

0 comments on commit 9d92609

Please sign in to comment.