diff --git a/pallets/smith-members/src/lib.rs b/pallets/smith-members/src/lib.rs index 61ae03eda8825dd30c5cdd9138ddfb375899be3f..bf8527957038796b8727699bad624c5cc4b2dea0 100644 --- a/pallets/smith-members/src/lib.rs +++ b/pallets/smith-members/src/lib.rs @@ -455,7 +455,7 @@ impl<T: Config> Pallet<T> { SmithStatus::Pending }; - if smith_meta.status == SmithStatus::Pending { + if previous_status != SmithStatus::Smith { // - postpone the expiration: a Pending smith cannot do anything but wait // this postponement is here to ease the process of becoming a smith let new_expires_on = diff --git a/pallets/smith-members/src/tests.rs b/pallets/smith-members/src/tests.rs index 46430f600cc2dd30b72de61afe26bf5d635746db..3f30805ea6fba656fe715c527ebe9266db4f970e 100644 --- a/pallets/smith-members/src/tests.rs +++ b/pallets/smith-members/src/tests.rs @@ -586,7 +586,6 @@ fn certifying_an_online_smith() { 5 )); // Smith can expire - // TODO: test failing because expires_on is not postponed to session 8 assert_eq!( Smiths::<Runtime>::get(5), Some(SmithMeta {