Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

[crypt.pl] uncovered, removal of a disk still forbidden

Unless it's the tiny disk.
  • Loading branch information...
commit 26f2c6bcf1654e134e49c9642bb24e0813787856 1 parent b6edc9c
@masak authored
Showing with 9 additions and 0 deletions.
  1. +9 −0 crypt.pl
View
9 crypt.pl
@@ -363,6 +363,15 @@ (&code, $ex_type, $message, &followup?)
is .covered_by, ['small disk'],
'.covered_by attribute';
};
+
+ $game.move('small disk', 'middle');
+ throws_exception
+ { $game.remove('medium disk') },
+ X::Hanoi::ForbiddenDiskRemoval,
+ 'removing a disk (-) uncovered, removal is still forbidden',
+ {
+ is .disk, 'medium disk', '.disk attribute';
+ };
}
done;
Please sign in to comment.
Something went wrong with that request. Please try again.