-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #403 from lwahonen/upstream
Fix SUCCEEDED and FAILED instead of trying to fix the bug where it's vis...
- Loading branch information
Showing
4 changed files
with
24 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
contrib/platform/test/com/sun/jna/platform/win32/COM/COMUtilsTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package com.sun.jna.platform.win32.COM; | ||
|
||
import junit.framework.TestCase; | ||
|
||
public class COMUtilsTest extends TestCase { | ||
|
||
public void testSUCCEEDED() throws Exception { | ||
assertTrue(COMUtils.SUCCEEDED(COMUtils.S_OK)); | ||
assertTrue(COMUtils.SUCCEEDED(COMUtils.S_FALSE)); | ||
assertFalse(COMUtils.SUCCEEDED(COMUtils.E_UNEXPECTED)); | ||
} | ||
|
||
public void testFAILED() throws Exception { | ||
assertFalse(COMUtils.FAILED(COMUtils.S_OK)); | ||
assertFalse(COMUtils.FAILED(COMUtils.S_FALSE)); | ||
assertTrue(COMUtils.FAILED(COMUtils.E_UNEXPECTED)); | ||
} | ||
} |