Skip to content

Commit

Permalink
Merge pull request #3485 from sisuresh/fix-invoke-test
Browse files Browse the repository at this point in the history
Fix InvokeHostFunctionTests

Reviewed-by: jonjove
  • Loading branch information
latobarita authored Aug 3, 2022
2 parents 9ca42fb + 4296f4c commit ddbb482
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 7 deletions.
53 changes: 49 additions & 4 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion src/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ log = "0.4.17"
cxx = "1.0"
im-rc = "15.0.0"
base64 = "0.13.0"
stellar-contract-env-host = { git = "https://github.com/stellar/rs-stellar-contract-env", rev = "5e6bd28", features = [
stellar-contract-env-host = { git = "https://github.com/stellar/rs-stellar-contract-env", rev = "8e6c6a2", features = [
"vm",
] }
4 changes: 2 additions & 2 deletions src/transactions/test/InvokeHostFunctionTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ deployContract(Application& app, std::vector<uint8_t> const& contract)
auto key = SecretKey::fromSeed(sha256("a1"));

// create signature
auto const& separator = "create_contract(nonce: u256, contract: Vec<u8>, "
auto const& separator = "create_contract_from_ed25519(contract: Vec<u8>, "
"salt: u256, key: u256, sig: Vec<u8>)";
SHA256 hasher;
hasher.add(separator);
Expand Down Expand Up @@ -378,7 +378,7 @@ TEST_CASE("invoke host function", "[tx][contract]")
{
// create signature
auto const& separator =
"create_contract(nonce: u256, contract: Vec<u8>, "
"create_contract_from_ed25519(contract: Vec<u8>, "
"salt: u256, key: u256, sig: Vec<u8>)";
uint256 salt = sha256("salt");
auto key = SecretKey::fromSeed(sha256("a1"));
Expand Down

0 comments on commit ddbb482

Please sign in to comment.