コード例 #1
0
        public void WhenTryingToGetFlexibleDataEntityItemItShouldThrow()
        {
            var entityMock = new EntityMock
            {
                ["shoe_size"] = 12
            };

            entityMock.TryGetValue("shoe_size", out var result)
            .Should().BeTrue();

            result.Should().Be(12);
        }
コード例 #2
0
        public void WhenTryingToGetWrongFlexibleDataEntityItemItShouldThrow()
        {
            var entityMock = new EntityMock
            {
                ["shoe_size"] = 12
            };

            entityMock.TryGetValue("pants_size", out var result)
            .Should().BeFalse();

            result.Should().BeNull();
        }