@Test
    public void testExporterConsistency() {
        //
        final boolean testXML = true;
        final boolean testLists = false;
        final boolean testMaps = true;
        final boolean printXML = false;

        // initialize data
        AssetManager assetManager = new DesktopAssetManager(true);
        ArrayList<JmeExporter> exporters = new ArrayList<JmeExporter>();
        ArrayList<JmeImporter> importers = new ArrayList<JmeImporter>();

        BinaryExporter be = new BinaryExporter();
        BinaryImporter bi = new BinaryImporter();
        exporters.add(be);
        importers.add(bi);

        if (testXML) {
            XMLExporter xe = new XMLExporter();
            XMLImporter xi = new XMLImporter();
            exporters.add(xe);
            importers.add(xi);
        }

        Node origin = new Node("origin");

        origin.setUserData("testInt", 10);
        origin.setUserData("testString", "ABC");
        origin.setUserData("testBoolean", true);
        origin.setUserData("testFloat", 1.5f);
        origin.setUserData("1", "test");
        if (testLists) {
            origin.setUserData("string-list", Arrays.asList("abc"));
            origin.setUserData("int-list", Arrays.asList(1, 2, 3));
            origin.setUserData("float-list", Arrays.asList(1f, 2f, 3f));
        }

        if (testMaps) {
            Map<String, Object> map = new HashMap<>();
            map.put("int", 1);
            map.put("string", "abc");
            map.put("float", 1f);
            origin.setUserData("map", map);
        }

        // export
        ByteArrayOutputStream outs[] = new ByteArrayOutputStream[exporters.size()];
        for (int i = 0; i < exporters.size(); i++) {
            JmeExporter exporter = exporters.get(i);
            outs[i] = new ByteArrayOutputStream();
            try {
                exporter.save(origin, outs[i]);
            } catch (IOException ex) {
                Assert.fail(ex.getMessage());
            }
        }

        // print
        if (printXML) {
            for (int i = 0; i < exporters.size(); i++) {
                ByteArrayOutputStream out = outs[i];
                if (exporters.get(i) instanceof XMLExporter) {
                    System.out.println("XML: \n" + new String(out.toByteArray()) + "\n\n");
                } else if (exporters.get(i) instanceof BinaryExporter) {
                    System.out.println("Binary: " + out.size() + " bytes");
                } else {
                    System.out.println("Unknown exporter: " + exporters.get(i).getClass().getName());
                }
            }
        }

        // import
        Node nodes[] = new Node[importers.size() + 1];
        nodes[0] = origin;
        for (int i = 0; i < importers.size(); i++) {
            JmeImporter importer = importers.get(i);
            ByteArrayOutputStream out = outs[i];
            try {
                AssetInfo info = new AssetInfo(assetManager, new ModelKey("origin")) {
                    @Override
                    public InputStream openStream() {
                        return new ByteArrayInputStream(out.toByteArray());
                    }
                };
                nodes[i + 1] = (Node) importer.load(info);
            } catch (IOException ex) {
                Assert.fail(ex.getMessage());
            }
        }

        // compare
        Map<String, Object> userData[] = new Map[nodes.length];
        for (int i = 0; i < nodes.length; i++) {
            Node n = nodes[i];
            userData[i] = new HashMap<String, Object>();
            for (String k : n.getUserDataKeys()) {
                userData[i].put(k, n.getUserData(k));
            }
        }
        compareMaps(userData);
    }
Tests the methods on classes that implements the JmeExporter interface.
jme3-plugins/src/test/java/com/jme3/export/JmeExporterTest.java