diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2017-05-18 22:38:35 +0900 |
---|---|---|
committer | Takeshi Abe <tabe@fixedpoint.jp> | 2017-05-19 10:32:36 +0200 |
commit | 2acc4dc6a97a279cca2703ed93ba5dd9911cfecf (patch) | |
tree | bf0fe8d98474d957ee7bef3003d0fe761580baa7 /basic/qa | |
parent | d880df3a44497cdec49017538a9d38d48e543bad (diff) |
basic: Fix broken unit test for IsMissing()
Change-Id: Ia6fb2622c85686a50701d4c37356e608a3df653b
Reviewed-on: https://gerrit.libreoffice.org/37775
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
Diffstat (limited to 'basic/qa')
-rw-r--r-- | basic/qa/vba_tests/ismissing.vb | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/basic/qa/vba_tests/ismissing.vb b/basic/qa/vba_tests/ismissing.vb index 36d2f746f985..496a57a533e7 100644 --- a/basic/qa/vba_tests/ismissing.vb +++ b/basic/qa/vba_tests/ismissing.vb @@ -6,7 +6,7 @@ Dim result As String Function doUnitTest() As String result = verify_testIsMissing() -If failCount <> 0 And passCount > 0 Then +If failCount <> 0 Or passCount = 0 Then doUnitTest = result Else doUnitTest = "OK" @@ -23,19 +23,16 @@ Function verify_testIsMissing() As String result = "Test Results" & Chr$(10) & "============" & Chr$(10) Dim testName As String - Dim TestDateTime As Date - Dim TestStr As String - Dim date1, date2 + Dim num1, num2 As Integer testName = "Test IsMissing function" On Error GoTo errorHandler - date2 = Null - date1 = ReturnTwice() - TestLog_ASSERT IsNull(date1), "the return IsMissing is: " & date1 + num1 = ReturnTwice() + TestLog_ASSERT IsNull(num1) - date2 = 4 - date1 = ReturnTwice(2) - TestLog_ASSERT date1 = date2, "the return IsMissing is: " & date1 + num2 = 4 + num1 = ReturnTwice(2) + TestLog_ASSERT num1 = num2, "the return IsMissing is: " & num1 result = result & Chr$(10) & "Tests passed: " & passCount & Chr$(10) & "Tests failed: " & failCount & Chr$(10) verify_testIsMissing = result |