-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'hotfix/4.5.2' into release/4.6 plus bump version for be…
…ta release Conflicts: WordPress/build.gradle
- Loading branch information
Showing
2 changed files
with
55 additions
and
11 deletions.
There are no files selected for viewing
32 changes: 32 additions & 0 deletions
32
WordPressUtils/src/androidTest/java/org/wordpress/android/util/JSONUtilsTest.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,32 @@ | ||
package org.wordpress.android.util; | ||
|
||
import android.test.InstrumentationTestCase; | ||
|
||
import org.json.JSONArray; | ||
import org.json.JSONObject; | ||
|
||
public class JSONUtilsTest extends InstrumentationTestCase { | ||
public void testQueryJSONNullSource1() { | ||
JSONUtils.queryJSON((JSONObject) null, "", ""); | ||
} | ||
|
||
public void testQueryJSONNullSource2() { | ||
JSONUtils.queryJSON((JSONArray) null, "", ""); | ||
} | ||
|
||
public void testQueryJSONNullQuery1() { | ||
JSONUtils.queryJSON(new JSONObject(), null, ""); | ||
} | ||
|
||
public void testQueryJSONNullQuery2() { | ||
JSONUtils.queryJSON(new JSONArray(), null, ""); | ||
} | ||
|
||
public void testQueryJSONNullReturnValue1() { | ||
JSONUtils.queryJSON(new JSONObject(), "", null); | ||
} | ||
|
||
public void testQueryJSONNullReturnValue2() { | ||
JSONUtils.queryJSON(new JSONArray(), "", null); | ||
} | ||
} |
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