Exemplo n.º 1
0
        public void CanBeConstructed()
        {
            //Arrange
            ReleaseApprovalPendingEvent sut;

            //Act
            sut = new ReleaseApprovalPendingEvent();

            //Assert
            Assert.NotNull(sut);
            Assert.Equal("ms.vss-release.deployment-approval-pending-event", ReleaseApprovalPendingEvent.EventIdentifier);
        }
Exemplo n.º 2
0
        public void CanBeSerialized()
        {
            //Arrange
            var sut = new ReleaseApprovalPendingEvent()
            {
                Id          = Guid.NewGuid().ToString(),
                EventType   = "MyEventType",
                PublisherId = "MyPublisherId",
                Scope       = "MyScope"
            };

            //Act
            var payload = JsonSerializer.Serialize(sut, new JsonSerializerOptions {
                IgnoreNullValues = true
            });

            //Assert
            Assert.NotNull(JsonDocument.Parse(payload));
        }