Created
September 28, 2020 05:56
-
-
Save yatender-oktalk/2e7df5eaf38ac43ca83935dd0929d701 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule ExChain.BlockchainTest do | |
.... | |
test "validate a chain", %{blockchain: blockchain} do | |
# add block into blockchain | |
blockchain = Blockchain.add_block(blockchain, "some-block-data") | |
# assert if blockchain is valid | |
assert Blockchain.valid_chain?(blockchain) | |
end | |
... | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment