Skip to content

Commit 04e7b11

Browse files
committed
fix test
1 parent 580306b commit 04e7b11

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

src/chain-libs/chain-impl-mockchain/src/accounting/account/mod.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,6 @@ pub enum LedgerError {
3131
AlreadyExists,
3232
#[error("Removed account is not empty")]
3333
NonZero,
34-
#[error("Spending credential invalid, expected {} got {} in lane {}", .expected.unlaned_counter(), .actual.unlaned_counter(), .actual.lane())]
35-
SpendingCredentialInvalid {
36-
expected: SpendingCounter,
37-
actual: SpendingCounter,
38-
},
3934
#[error("Value calculation failed")]
4035
ValueError(#[from] ValueError),
4136
#[error(transparent)]

src/chain-libs/chain-impl-mockchain/src/ledger/tests/transaction_tests.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,12 @@ pub fn duplicated_account_transaction() {
130130
match result {
131131
Err(err) => panic!("first transaction should be succesful but {}", err),
132132
Ok(_) => match test_ledger.apply_transaction(fragment2, BlockDate::first()) {
133-
Err(ledger::Error::Account(
134-
crate::account::LedgerError::SpendingCredentialInvalid { expected, actual },
135-
)) => {
133+
Err(ledger::Error::Account(crate::account::LedgerError::SpendingCounterError(
134+
crate::accounting::account::spending::Error::SpendingCredentialInvalid {
135+
expected,
136+
actual,
137+
},
138+
))) => {
136139
assert_eq!(expected, SpendingCounter::zero().increment());
137140
assert_eq!(actual, SpendingCounter::zero());
138141
}

0 commit comments

Comments
 (0)