/*
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.httprpc.io;

import java.io.IOException;
import java.io.StringWriter;
import java.util.List;
import java.util.Map;

import org.httprpc.AbstractTest;
import org.junit.Assert;
import org.junit.Ignore;
import org.junit.Test;

public class XMLEncoderTest extends AbstractTest {
    @Test
    @Ignore // TODO
    public void testWrite() throws IOException {
        String expected = ""; // TODO

        List<Map<String, ?>> values = listOf(); // TODO

        StringWriter writer = new StringWriter();

        XMLEncoder xmlEncoder = new XMLEncoder("test");

        xmlEncoder.write(values, writer);

        Assert.assertEquals(expected, writer.toString());
    }
}

@@ -637,16 +637,67 @@
 Writer;%0A
+import java.time.DayOfWeek;%0Aimport java.util.Date;%0A
 import j
@@ -707,24 +707,24 @@
 .util.List;%0A
-
 import java.
@@ -796,33 +796,8 @@
 rt;%0A
-import org.junit.Ignore;%0A
 impo
@@ -881,28 +881,8 @@
 est%0A
-    @Ignore // TODO%0A
     
@@ -1014,18 +1014,467 @@
 tOf(
-); // TODO
+%0A            mapOf(%0A                entry(%22a%22, %22ABC%22),%0A                entry(%22b%22, 1),%0A                entry(%22c%22, 2.345),%0A                entry(%22d%22, mapOf(%0A                    entry(%22e%22, true)%0A                )),%0A                entry(%22f%22, new Date(0)),%0A                entry(%22g%22, DayOfWeek.THURSDAY)%0A            ),%0A            mapOf(%0A                entry(%22a%22, %22D%C3%89F%22),%0A                entry(%22b%22, 2),%0A                entry(%22c%22, 4.5678)%0A            )%0A        );
 %0A%0A  

Update XMLEncoder test.