Kaydet (Commit) 2acc4dc6 authored tarafından Takeshi Abe's avatar Takeshi Abe

basic: Fix broken unit test for IsMissing()

Change-Id: Ia6fb2622c85686a50701d4c37356e608a3df653b
Reviewed-on: https://gerrit.libreoffice.org/37775Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarTakeshi Abe <tabe@fixedpoint.jp>
üst d880df3a
......@@ -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
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment