public void test_WriteEmptyArray() {
Exception ex = null;
try{
StringWriter w = new StringWriter();
JSONWriter jWriter = new JSONWriter(w);
jWriter.array();
jWriter.endArray();
String str = w.toString();
// Verify it parses.
JSONArray test = new JSONArray(str);
assertTrue(str.equals("[]"));