Esempio n. 1
0
        public void WriteConstructor()
        {
            ExceptionAssert.Throws <JsonWriterException>(() =>
            {
                MemoryStream ms       = new MemoryStream();
                CborDataWriter writer = new CborDataWriter(ms);

                writer.WriteStartArray();
                writer.WriteStartConstructor("fail");
            }, "Cannot write JSON constructor as BSON. Path ''.");
        }