File tree Expand file tree Collapse file tree 1 file changed +45
-0
lines changed
RubberduckTests/IntegrationTests Expand file tree Collapse file tree 1 file changed +45
-0
lines changed Original file line number Diff line number Diff line change @@ -729,3 +729,48 @@ TestExit:
729
729
TestFail:
730
730
Assert.Fail "Test raised an error: #" & Err.Number & " - " & Err.Description
731
731
End Sub
732
+
733
+ '@TestMethod
734
+ Public Sub TestIssue4476 ()
735
+ On Error GoTo TestFail
736
+
737
+ 'Arrange:
738
+ Fakes.Now.PassThrough = True
739
+ Fakes.Date .PassThrough = True
740
+
741
+ 'Act:
742
+ Debug.Print Now
743
+ Debug.Print Date '<== KA-BOOOM
744
+
745
+ 'Assert:
746
+ Fakes.Now.Verify.AtLeastOnce
747
+ Fakes.Date .Verify.AtLeastOnce
748
+
749
+ TestExit:
750
+ Exit Sub
751
+ TestFail:
752
+ Assert.Fail "Test raised an error: #" & Err.Number & " - " & Err.Description
753
+ End Sub
754
+
755
+ '@TestMethod
756
+ Public Sub TestIssue5944 ()
757
+ On Error GoTo TestFail
758
+
759
+ Fakes.InputBox.Returns 20
760
+ Fakes.MsgBox.Returns 20
761
+
762
+ Dim inputBoxReturnValue As String
763
+ Dim msgBoxReturnValue As Integer
764
+
765
+ inputBoxReturnValue = InputBox("Dummy" )
766
+ msgBoxReturnValue = MsgBox("Dummy" )
767
+
768
+ Fakes.MsgBox.Verify.Once
769
+ Fakes.InputBox.Verify.Once
770
+
771
+ TestExit:
772
+ Exit Sub
773
+ TestFail:
774
+ Assert.Fail "Test raised an error: #" & Err.Number & " - " & Err.Description
775
+ End Sub
776
+
You can’t perform that action at this time.
0 commit comments