package com.github.rschmitt.dynamicobject;

import org.junit.After;
import org.junit.Before;
import org.junit.Test;

import static org.junit.Assert.assertEquals;

public class RecordTest {
    @Before
    public void setup() {
        DynamicObject.registerTag(Defrecord.class, "com.github.rschmitt.dynamicobject.Defrecord");
    }

    @After
    public void teardown() {
        DynamicObject.deregisterTag(Defrecord.class, "com.github.rschmitt.dynamicobject.Defrecord");
    }

    @Test
    public void roundTrip() {
        String edn = "#com.github.rschmitt.dynamicobject.Defrecord{:str \"a string\"}";

        Defrecord record = DynamicObject.deserialize(edn, Defrecord.class);

        assertEquals("a string", record.str());
        assertEquals(edn, DynamicObject.serialize(record));
//        assertEquals(edn, record.toFormattedString());
    }
}

interface Defrecord extends DynamicObject<Defrecord> {
    String str();
}
@@ -112,24 +112,64 @@
 it.Test;%0D%0A%0D%0A
+import static java.lang.String.format;%0D%0A
 import stati
@@ -859,34 +859,288 @@
 );%0D%0A
-//        assertEquals(edn
+    %7D%0D%0A%0D%0A    @Test%0D%0A    public void pprintOmitsReaderTag() %7B%0D%0A        String edn = %22#com.github.rschmitt.dynamicobject.Defrecord%7B:str %5C%22a string%5C%22%7D%22;%0D%0A        Defrecord record = DynamicObject.deserialize(edn, Defrecord.class);%0D%0A        assertEquals(format(%22%7B:str %5C%22a string%5C%22%7D%25n%22)
 , re

Add a test for pprint behavior