Skip to content

Commit

Permalink
Auto-generate scenarios unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
CostinCarabas committed Dec 27, 2023
1 parent 13cb2d4 commit a438fa2
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion esdt-safe/scenarios/setup_accounts.scen.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"steps": [
{
"step": "externalSteps",
"path": "../../price-aggregator/mandos/get_latest_price_feed.scen.json"
"path": "../../price-aggregator/scenarios/get_latest_price_feed.scen.json"
},
{
"step": "setState",
Expand Down
6 changes: 5 additions & 1 deletion esdt-safe/tests/esdt_safe_scenario_rs_test.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
use multiversx_sc_scenario::*;

fn world() -> ScenarioWorld {
todo!()
let mut blockchain = ScenarioWorld::new();
blockchain.set_current_dir_from_workspace("esdt-safe/");

blockchain.register_contract("file:output/esdt-safe.wasm", esdt_safe::ContractBuilder);
blockchain
}

#[test]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"steps": [
{
"step": "externalSteps",
"path": "../../bridged-tokens-wrapper/mandos/whitelist_token.scen.json"
"path": "../../bridged-tokens-wrapper/scenarios/whitelist_token.scen.json"
},
{
"step": "setState",
Expand Down
2 changes: 1 addition & 1 deletion multisig/scenarios/setup.scen.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"steps": [
{
"step": "externalSteps",
"path": "../../price-aggregator/mandos/oracle_gwei_in_eth_and_egld_submit.scen.json"
"path": "../../price-aggregator/scenarios/oracle_gwei_in_eth_and_egld_submit.scen.json"
},
{
"step": "setState",
Expand Down
6 changes: 5 additions & 1 deletion multisig/tests/multisig_scenario_rs_test.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
use multiversx_sc_scenario::*;

fn world() -> ScenarioWorld {
todo!()
let mut blockchain = ScenarioWorld::new();
blockchain.set_current_dir_from_workspace("multisig/");

blockchain.register_contract("file:output/multisig.wasm", multisig::ContractBuilder);
blockchain
}

#[test]
Expand Down

0 comments on commit a438fa2

Please sign in to comment.