@Test
public void testGetPrefixes() throws Exception {

  testGetPrefixes(new XmlNamespaceContext(Collections.map(
                          tuple("foo", "http://foo.org"),
                          tuple("bar", "http://bar.org"),
                          tuple("baz", "http://bar.org"))),
                  asList("bar", "baz"));
  testGetPrefixes(XmlNamespaceContext.mk(asList(
                          new XmlNamespaceBinding("foo", "http://foo.org"),
                          new XmlNamespaceBinding("bar", "http://bar.org"),
                          new XmlNamespaceBinding("baz", "http://bar.org"))),
                  asList("bar", "baz"));
}