mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 14:01:06 +00:00
Allow pallet-election-provider to accept smaller solutions as well (#10905)
* Allow `pallet-election-provider` to accept smaller solutions, issue #9478 * Fixing a typo * Adding some more tests Removing a seemingly outdated comment * making it a URL * Updating test name as per suggestion Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> * Updating documentation to be more explicit And to follow the general guidelines Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> * Fixing formatting Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This commit is contained in:
@@ -1044,8 +1044,13 @@ mod tests {
|
||||
roll_to(25);
|
||||
assert!(MultiPhase::current_phase().is_unsigned());
|
||||
|
||||
// Force the number of winners to be bigger to fail
|
||||
let (mut solution, _) =
|
||||
MultiPhase::mine_solution::<<Runtime as Config>::Solver>().unwrap();
|
||||
solution.solution.votes1[0].1 = 4;
|
||||
|
||||
assert_eq!(
|
||||
MultiPhase::mine_check_save_submit().unwrap_err(),
|
||||
MultiPhase::basic_checks(&solution, "mined").unwrap_err(),
|
||||
MinerError::PreDispatchChecksFailed(DispatchError::Module(ModuleError {
|
||||
index: 2,
|
||||
error: 1,
|
||||
|
||||
Reference in New Issue
Block a user