File tree 2 files changed +6
-2
lines changed
test/JsonApiDotNetCoreTests/IntegrationTests/QueryStrings 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,8 @@ public sealed class Blog : Identifiable<int>
17
17
[ Attr ( Capabilities = AttrCapabilities . All & ~ ( AttrCapabilities . AllowCreate | AttrCapabilities . AllowChange ) ) ]
18
18
public bool ShowAdvertisements => PlatformName . EndsWith ( "(using free account)" , StringComparison . Ordinal ) ;
19
19
20
+ public bool IsPublished { get ; set ; }
21
+
20
22
[ HasMany ]
21
23
public IList < BlogPost > Posts { get ; set ; } = new List < BlogPost > ( ) ;
22
24
Original file line number Diff line number Diff line change @@ -749,6 +749,7 @@ public async Task Retrieves_all_properties_when_fieldset_contains_readonly_attri
749
749
store . Clear ( ) ;
750
750
751
751
Blog blog = _fakers . Blog . Generate ( ) ;
752
+ blog . IsPublished = true ;
752
753
753
754
await _testContext . RunOnDatabaseAsync ( async dbContext =>
754
755
{
@@ -771,7 +772,8 @@ await _testContext.RunOnDatabaseAsync(async dbContext =>
771
772
responseDocument . Data . SingleValue . Relationships . Should ( ) . BeNull ( ) ;
772
773
773
774
var blogCaptured = ( Blog ) store . Resources . Should ( ) . ContainSingle ( resource => resource is Blog ) . And . Subject . Single ( ) ;
774
- blogCaptured . ShowAdvertisements . Should ( ) . Be ( blogCaptured . ShowAdvertisements ) ;
775
+ blogCaptured . ShowAdvertisements . Should ( ) . Be ( blog . ShowAdvertisements ) ;
776
+ blogCaptured . IsPublished . Should ( ) . Be ( blog . IsPublished ) ;
775
777
blogCaptured . Title . Should ( ) . Be ( blog . Title ) ;
776
778
}
777
779
@@ -817,7 +819,7 @@ await _testContext.RunOnDatabaseAsync(async dbContext =>
817
819
var postCaptured = ( BlogPost ) store . Resources . Should ( ) . ContainSingle ( resource => resource is BlogPost ) . And . Subject . Single ( ) ;
818
820
postCaptured . Id . Should ( ) . Be ( post . Id ) ;
819
821
postCaptured . Caption . Should ( ) . Be ( post . Caption ) ;
820
- postCaptured . Url . Should ( ) . Be ( postCaptured . Url ) ;
822
+ postCaptured . Url . Should ( ) . Be ( post . Url ) ;
821
823
}
822
824
823
825
[ Fact ]
You can’t perform that action at this time.
0 commit comments