Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mraszyk committed Dec 6, 2024
1 parent b60e2b1 commit 1bc25a0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion motoko/classes/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ all: build
.PHONY: build
.SILENT: build
build:
dfx canister create --all
dfx canister create --all --no-wallet
dfx build

.PHONY: install
Expand Down
2 changes: 1 addition & 1 deletion motoko/composite_query/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ all: build
.PHONY: build
.SILENT: build
build:
dfx canister create --all
dfx canister create --all --no-wallet
dfx build

.PHONY: install
Expand Down
10 changes: 5 additions & 5 deletions motoko/hello_cycles/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,19 @@ test: install
echo "wallet: $(WALLET)"
echo "hello_cycles: $(HELLO_CYCLES)"
echo "$(dfx canister call hello_cycles wallet_balance)"
# canister has just above 2.98T cycles, so output start with '(2_98'
# canister has just above 2.5T cycles, so output start with '(2_5'
dfx canister call hello_cycles wallet_balance \
| grep '(2_98' && echo 'PASS'
| grep '(2_5' && echo 'PASS'
dfx canister status hello_cycles
dfx canister call $(WALLET) wallet_send '(record { canister = principal "$(HELLO_CYCLES)"; amount = (2000000000000:nat64); } )'
# 2T cycles added, now contains just above 4.98T
# 2T cycles added, now contains just above 4.5T
dfx canister call hello_cycles wallet_balance \
| grep '(4_98' && echo 'PASS'
| grep '(4_5' && echo 'PASS'
echo '(func "$(WALLET)"."wallet_receive", 5000000)'
dfx canister call hello_cycles transfer '(func "$(WALLET)"."wallet_receive", 5000000)' \
| grep '0' && echo 'PASS'
dfx canister call hello_cycles wallet_balance \
| grep '(4_98' && echo 'PASS'
| grep '(4_5' && echo 'PASS'

.PHONY: clean
.SILENT: clean
Expand Down

0 comments on commit 1bc25a0

Please sign in to comment.