public void FailValidation()
        {
            var db = TestDatastoreClient.Create();
            var x  = new ValidatedSample {
                Name = "hello world!"
            };

            Assert.Throws <ValidationException>(() => db.Insert(x));
            Assert.Throws <ValidationException>(() => db.Upsert(x));
            Assert.Throws <ValidationException>(() => db.Update(x));
            x.Name = "foo";
            db.Upsert(x);
        }
        public static void FailValidation()
        {
            var db = Open();
            var x  = new ValidatedSample {
                Name = "hello world!"
            };

            Assert.Throws <ValidationException>(() => db.Insert(x));
            Assert.Throws <ValidationException>(() => db.Upsert(x));
            Assert.Throws <ValidationException>(() => db.Update(x));
            x.Name = "foo";
            db.Upsert(x);
        }