Advertisement
Guest User

Untitled

a guest
Jan 26th, 2015
230
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 2.99 KB | None | 0 0
  1. [TestMethod]
  2. [TestCategory("Unit")]
  3. public void FlipHorizontalCommand_NoActiveImage_CannotBeExecuted()
  4. {
  5.     SetupNoActiveImage();
  6.     var canExecute = _vm.FlipHorizontalCommand.CanExecute(null);
  7.     canExecute.Should().BeFalse();
  8. }
  9.  
  10. [TestMethod]
  11. [TestCategory("Unit")]
  12. public void FlipVerticalCommand_NoActiveImage_CannotBeExecuted()
  13. {
  14.     SetupNoActiveImage();
  15.     var canExecute = _vm.FlipVerticalCommand.CanExecute(null);
  16.     canExecute.Should().BeFalse();
  17. }
  18.  
  19. [TestMethod]
  20. [TestCategory("Unit")]
  21. public void RotateCommand_NoActiveImage_CannotBeExecuted()
  22. {
  23.     SetupNoActiveImage();
  24.     var canExecute = _vm.RotateCommand.CanExecute(null);
  25.     canExecute.Should().BeFalse();
  26. }
  27.  
  28. [TestMethod]
  29. [TestCategory("Unit")]
  30. public void RemoveCommand_NoActiveImage_CannotBeExecuted()
  31. {
  32.     SetupNoActiveImage();
  33.     var canExecute = _vm.RemoveCommand.CanExecute(null);
  34.     canExecute.Should().BeFalse();
  35. }
  36.  
  37. [TestMethod]
  38. [TestCategory("Unit")]
  39. public void FlipHorizontalCommand_ActiveImageAvailable_CanBeExecuted()
  40. {
  41.     SetupActiveImageAvailable();
  42.     var canExecute = _vm.FlipHorizontalCommand.CanExecute(null);
  43.     canExecute.Should().BeTrue();
  44. }
  45.  
  46. [TestMethod]
  47. [TestCategory("Unit")]
  48. public void FlipVerticalCommand_ActiveImageAvailable_CanBeExecuted()
  49. {
  50.     SetupActiveImageAvailable();
  51.     var canExecute = _vm.FlipVerticalCommand.CanExecute(null);
  52.     canExecute.Should().BeTrue();
  53. }
  54.  
  55. [TestMethod]
  56. [TestCategory("Unit")]
  57. public void RotateCommand_ActiveImageAvailable_CanBeExecuted()
  58. {
  59.     SetupActiveImageAvailable();
  60.     var canExecute = _vm.RotateCommand.CanExecute(null);
  61.     canExecute.Should().BeTrue();
  62. }
  63.  
  64. [TestMethod]
  65. [TestCategory("Unit")]
  66. public void RemoveCommand_ActiveImageAvailable_CanBeExecuted()
  67. {
  68.     SetupActiveImageAvailable();
  69.     var canExecute = _vm.RemoveCommand.CanExecute(null);
  70.     canExecute.Should().BeTrue();
  71. }
  72.  
  73. [TestMethod]
  74. [TestCategory("Unit")]
  75. public void FlipHorizontalCommand_ActiveImageAvailableButModificationsNotAllowed_CannotBeExecuted()
  76. {
  77.     SetupActiveImageButDisallowModifications();
  78.     var canExecute = _vm.FlipHorizontalCommand.CanExecute(null);
  79.     canExecute.Should().BeFalse();
  80. }
  81.  
  82. [TestMethod]
  83. [TestCategory("Unit")]
  84. public void FlipVerticalCommand_ActiveImageAvailableButModificationsNotAllowed_CannotBeExecuted()
  85. {
  86.     SetupActiveImageButDisallowModifications();
  87.     var canExecute = _vm.FlipVerticalCommand.CanExecute(null);
  88.     canExecute.Should().BeFalse();
  89. }
  90.  
  91. [TestMethod]
  92. [TestCategory("Unit")]
  93. public void RotateCommand_ActiveImageAvailableButModificationsNotAllowed_CannotBeExecuted()
  94. {
  95.     SetupActiveImageButDisallowModifications();
  96.     var canExecute = _vm.RotateCommand.CanExecute(null);
  97.     canExecute.Should().BeFalse();
  98. }
  99.  
  100. [TestMethod]
  101. [TestCategory("Unit")]
  102. public void RemoveCommand_ActiveImageAvailableButModificationsNotAllowed_CannotBeExecuted()
  103. {
  104.     SetupActiveImageButDisallowModifications();
  105.     var canExecute = _vm.RemoveCommand.CanExecute(null);
  106.     canExecute.Should().BeFalse();
  107. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement