s/contract/program

This commit is contained in:
Anatoly Yakovenko
2018-09-19 17:25:57 -07:00
committed by Michael Vines
parent 6073cd57fa
commit 9bfead2e01
7 changed files with 147 additions and 148 deletions

View File

@@ -68,15 +68,15 @@ mod tests {
use super::*;
use bincode::deserialize;
use ledger::Block;
use system_contract::SystemContract;
use system_program::SystemProgram;
#[test]
fn test_create_transactions() {
let mut transactions = Mint::new(100).create_transactions().into_iter();
let tx = transactions.next().unwrap();
assert!(SystemContract::check_id(&tx.contract_id));
let instruction: SystemContract = deserialize(&tx.userdata).unwrap();
if let SystemContract::Move { tokens } = instruction {
assert!(SystemProgram::check_id(&tx.program_id));
let instruction: SystemProgram = deserialize(&tx.userdata).unwrap();
if let SystemProgram::Move { tokens } = instruction {
assert_eq!(tokens, 100);
}
assert_eq!(transactions.next(), None);