Beispiel #1
0
 public void writeCallsWriterWritePlainLiteralOnceWithLanguage() {
   RdfWriterCounter writer = new RdfWriterCounter();
   PlainLiteral instance = new PlainLiteral("whizz", "en");
   
   instance.Write(writer);
   
   Assert.AreEqual( 1, writer.WritePlainLiteralLanguageCalled );
 }
Beispiel #2
0
        public void writeCallsWriterWriteTypedLiteralOnce()
        {
            RdfWriterCounter writer   = new RdfWriterCounter();
            TypedLiteral     instance = new TypedLiteral("whizz", "http://example.com/datatype");

            instance.Write(writer);

            Assert.AreEqual(1, writer.WriteTypedLiteralCalled);
        }
Beispiel #3
0
        public void writeCallsWriterWriteUriRefOnce()
        {
            RdfWriterCounter writer   = new RdfWriterCounter();
            UriRef           instance = new UriRef("http://example.com/subject");

            instance.Write(writer);

            Assert.AreEqual(1, writer.WriteUriRefCalled);
        }
Beispiel #4
0
        public void writeCallsWriterEndOutputOnce()
        {
            RdfWriterCounter writer = new RdfWriterCounter();
            TripleStore      store  = MakeNewTripleStore();

            store.Write(writer);

            Assert.AreEqual(1, writer.EndOutputCalled);
            store.Clear();
        }