コード例 #1
0
        protected virtual void CodeBasedSerializes()
        {
            var descriptor = new PutMappingDescriptor <T>().Properties(FluentProperties);

            if (this.AutoMap)
            {
                descriptor.AutoMap();
            }
            Expect(ExpectJson)
            .WhenSerializing(descriptor as IPutMappingRequest);

            if (ExpectJsonFluentOnly != null)
            {
                Expect(ExpectJsonFluentOnly)
                .WhenSerializing(new PutMappingDescriptor <T>().Properties(FluentOnlyProperties) as IPutMappingRequest);
            }
        }