Skip to content

Commit b69661b

Browse files
committed
fix(tests): fix eligibility tests
1 parent ea93e5c commit b69661b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

validations/src/eligibility/current.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ where
154154
Err(e) => {
155155
// Early exit if the stake key does not exist
156156
return match e {
157-
StakesError::EntryNotFound { .. } => Ok(IneligibilityReason::NotStaking.into()),
157+
StakesError::ValidatorNotFound { .. } => Ok(IneligibilityReason::NotStaking.into()),
158158
e => Err(e),
159159
};
160160
}
@@ -189,7 +189,7 @@ where
189189
Err(e) => {
190190
// Early exit if the stake key does not exist
191191
return match e {
192-
StakesError::EntryNotFound { .. } => {
192+
StakesError::ValidatorNotFound { .. } => {
193193
Ok((IneligibilityReason::NotStaking.into(), Hash::min(), 0.0))
194194
}
195195
e => Err(e),
@@ -264,7 +264,7 @@ mod tests {
264264
let mut stakes = <Stakes<String, _, _, _>>::with_minimum(100u64);
265265
let isk = "validator";
266266

267-
stakes.add_stake(isk, 1_000, 0).unwrap();
267+
stakes.add_stake(isk, 10_000_000_000, 0).unwrap();
268268

269269
assert_eq!(
270270
stakes.mining_eligibility(isk, 0),
@@ -303,7 +303,7 @@ mod tests {
303303
let mut stakes = <Stakes<String, _, _, _>>::with_minimum(100u64);
304304
let isk = "validator";
305305

306-
stakes.add_stake(isk, 1_000, 0).unwrap();
306+
stakes.add_stake(isk, 10_000_000_000, 0).unwrap();
307307

308308
match stakes.witnessing_eligibility(isk, 0, 10, 0) {
309309
Ok((eligible, _, _)) => {

0 commit comments

Comments
 (0)