package br.com.softctrl.utils.java;

import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;

/**
 * Unit test for simple App.
 */
public class GSonUtilsTest extends TestCase {
    /**
     * Create the test case
     *
     * @param testName
     *            name of the test case
     */
    public GSonUtilsTest(String testName) {
        super(testName);
    }

    /**
     * @return the suite of tests being tested
     */
    public static Test suite() {
        return new TestSuite(GSonUtilsTest.class);
    }

    /**
     * Rigourous Test :-)
     */
    public void testApp() {
        assertTrue(true);
    }
}

@@ -30,16 +30,129 @@
 .java;%0A%0A
+import java.util.Date;%0A%0Aimport com.google.gson.annotations.Expose;%0A%0Aimport br.com.softctrl.utils.json.GsonUtils;%0A
 import j
@@ -327,55 +327,486 @@
 e %7B%0A
-    /**%0A     * Create the test case%0A     *%0A    
+%0A%09public static class Dummy %7B%0A%09%09@Expose%0A%09%09public byte vlr0;%0A%09%09@Expose%0A%09%09public boolean vlr1;%0A%09%09@Expose%0A%09%09public char vlr2;%0A%09%09@Expose%0A%09%09public double vlr3;%0A%09%09@Expose%0A%09%09public float vlr4;%0A%09%09@Expose%0A%09%09public int vlr5;%0A%09%09@Expose%0A%09%09public short vlr6;%0A%09%09@Expose%0A%09%09public Boolean vlr7;%0A%09%09@Expose%0A%09%09public Double vlr8;%0A%09%09@Expose%0A%09%09public Float vlr9;%0A%09%09@Expose%0A%09%09public Integer vlr10;%0A%09%09@Expose%0A%09%09public Short vlr11;%0A%09%09@Expose%0A%09%09public Date vlr12;%0A%09%7D%0A%0A%09/**%0A%09 * Create the test case%0A%09 *%0A%09
  * @
@@ -820,20 +820,17 @@
 estName%0A
-    
+%09
  *      
@@ -857,28 +857,22 @@
 st case%0A
-     */%0A    
+%09 */%0A%09
 public G
@@ -903,24 +903,18 @@
 Name) %7B%0A
-        
+%09%09
 super(te
@@ -922,35 +922,26 @@
 tName);%0A
-    %7D%0A%0A    /**%0A    
+%09%7D%0A%0A%09/**%0A%09
  * @retu
@@ -975,28 +975,22 @@
  tested%0A
-     */%0A    
+%09 */%0A%09
 public s
@@ -1010,24 +1010,18 @@
 ite() %7B%0A
-        
+%09%09
 return n
@@ -1059,27 +1059,18 @@
 s);%0A
-    %7D%0A%0A    /**%0A    
+%09%7D%0A%0A%09/**%0A%09
  * R
@@ -1091,20 +1091,14 @@
 :-)%0A
-     */%0A    
+%09 */%0A%09
 publ
@@ -1113,46 +1113,340 @@
 test
-App() %7B%0A        assertTrue(true);%0A    %7D
+GsonUtilsToJson() %7B%0A%09%09final String espected = %22%7B%5C%22vlr0%5C%22:0,%5C%22vlr1%5C%22:false,%5C%22vlr2%5C%22:%5C%22%5Cu0000%5C%22,%5C%22vlr3%5C%22:0.0,%5C%22vlr4%5C%22:0.0,%5C%22vlr5%5C%22:0,%5C%22vlr6%5C%22:0,%5C%22vlr7%5C%22:null,%5C%22vlr8%5C%22:null,%5C%22vlr9%5C%22:null,%5C%22vlr10%5C%22:null,%5C%22vlr11%5C%22:null,%5C%22vlr12%5C%22:null%7D%22;%0A%09%09final String received = GsonUtils.toJson(new Dummy());%0A%09%09assertTrue(espected.equals(received));%0A%09%7D%0A
 %0A%7D%0A

Create a first test.