@Test
    public void testNews3() throws Exception {
        // Updating all elements in a documentType
        VespaXMLFeedReader parser = new VespaXMLFeedReader("src/test/vespaxmlparser/test03.xml", manager);
        FeedOperation op = parser.read();

        assertEquals(FeedOperation.Type.UPDATE, op.getType());

        DocumentUpdate docUpdate = op.getDocumentUpdate();

        //url
        assertEquals(new StringFieldValue("assignUrl"), docUpdate.getFieldUpdate("url").getValueUpdate(0).getValue());

        //title
        assertEquals(new StringFieldValue("assignTitle"),
                     docUpdate.getFieldUpdate("title").getValueUpdate(0).getValue());

        //last_downloaded
        assertEquals(new IntegerFieldValue(1),
                     docUpdate.getFieldUpdate("last_downloaded").getValueUpdate(0).getValue());

        //value_long
        assertEquals(new LongFieldValue((long)2), docUpdate.getFieldUpdate("value_long").getValueUpdate(0).getValue());

        //stringarr
        List stringarr = (List)docUpdate.getFieldUpdate("stringarr").getValueUpdate(0).getValue();
        assertEquals(new StringFieldValue("assignString1"), stringarr.get(0));
        assertEquals(new StringFieldValue("assignString2"), stringarr.get(1));

        //intarr
        List intarr = (List)docUpdate.getFieldUpdate("intarr").getValueUpdate(0).getValue();
        assertEquals(new IntegerFieldValue(3), intarr.get(0));
        assertEquals(new IntegerFieldValue(4), intarr.get(1));

        //longarr
        List longarr = (List)docUpdate.getFieldUpdate("longarr").getValueUpdate(0).getValue();
        assertEquals(new LongFieldValue((long)5), longarr.get(0));
        assertEquals(new LongFieldValue((long)6), longarr.get(1));

        //bytearr
        List bytearr = (List)docUpdate.getFieldUpdate("bytearr").getValueUpdate(0).getValue();
        assertEquals(new ByteFieldValue((byte)7), bytearr.get(0));
        assertEquals(new ByteFieldValue((byte)8), bytearr.get(1));

        //floatarr
        List floatarr = (List)docUpdate.getFieldUpdate("floatarr").getValueUpdate(0).getValue();
        assertEquals(new FloatFieldValue((float)9), floatarr.get(0));
        assertEquals(new FloatFieldValue((float)10), floatarr.get(1));

        //weightedsetint
        WeightedSet weightedsetint =
                (WeightedSet)docUpdate.getFieldUpdate("weightedsetint").getValueUpdate(0).getValue();
        assertEquals(Integer.valueOf(11), weightedsetint.get(new IntegerFieldValue(11)));
        assertEquals(Integer.valueOf(12), weightedsetint.get(new IntegerFieldValue(12)));

        //weightedsetstring
        WeightedSet weightedsetstring =
                (WeightedSet)docUpdate.getFieldUpdate("weightedsetstring").getValueUpdate(0).getValue();
        assertEquals(Integer.valueOf(13), weightedsetstring.get(new StringFieldValue("assign13")));
        assertEquals(Integer.valueOf(14), weightedsetstring.get(new StringFieldValue("assign14")));

    }
Simple test case for Vespa XML parser.

@author sveina
document/src/test/java/com/yahoo/vespaxmlparser/VespaXMLReaderTestCase.java