forked from wiztools/rest-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
84 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
55 changes: 55 additions & 0 deletions
55
restclient-ui/src/test/java/org/wiztools/restclient/ui/update/AppUpdateRunnerTest.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,55 @@ | ||
package org.wiztools.restclient.ui.update; | ||
|
||
import org.junit.After; | ||
import org.junit.AfterClass; | ||
import org.junit.Before; | ||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
import static org.junit.Assert.*; | ||
import org.wiztools.appupdate.VersionImpl; | ||
|
||
/** | ||
* | ||
* @author subhash | ||
*/ | ||
public class AppUpdateRunnerTest { | ||
|
||
public AppUpdateRunnerTest() { | ||
} | ||
|
||
@BeforeClass | ||
public static void setUpClass() { | ||
} | ||
|
||
@AfterClass | ||
public static void tearDownClass() { | ||
} | ||
|
||
@Before | ||
public void setUp() { | ||
} | ||
|
||
@After | ||
public void tearDown() { | ||
} | ||
|
||
/** | ||
* Test of doUpdateCheck method, of class AppUpdateRunner. | ||
*/ | ||
@Test | ||
public void testDoUpdateCheck() { | ||
System.out.println("doUpdateCheck"); | ||
long lastUpdateCheck = 0L; | ||
AppUpdateRunner instance = new AppUpdateRunner(); | ||
boolean expResult = true; | ||
boolean result = instance.doUpdateCheck(lastUpdateCheck); | ||
assertEquals(expResult, result); | ||
} | ||
|
||
@Test | ||
public void testRequiresUpdate() throws Exception { | ||
AppUpdateRunner instance = new AppUpdateRunner(); | ||
boolean result = instance.requiresUpdate(new VersionImpl("10.0")); | ||
assertTrue(result); | ||
} | ||
} |