コード例 #1
0
        public void SetStoreGeneratedPattern_should_update_existing_annotation()
        {
            var property = new EdmProperty().AsPrimitive();

            property.SetStoreGeneratedPattern(DbStoreGeneratedPattern.Computed);
            property.SetStoreGeneratedPattern(DbStoreGeneratedPattern.None);

            var storeGeneratedPattern = property.GetStoreGeneratedPattern();

            Assert.NotNull(storeGeneratedPattern);
            Assert.Equal(DbStoreGeneratedPattern.None, storeGeneratedPattern);
        }
コード例 #2
0
        public void SetStoreGeneratedPattern_should_create_annotation_and_add_to_property_facets()
        {
            var property = new EdmProperty().AsPrimitive();

            property.SetStoreGeneratedPattern(DbStoreGeneratedPattern.Computed);

            var storeGeneratedPattern = property.GetStoreGeneratedPattern();

            Assert.NotNull(storeGeneratedPattern);
            Assert.Equal(DbStoreGeneratedPattern.Computed, storeGeneratedPattern);
        }