示例#1
0
        public void Empty_ShouldBeFalse_WhenReleaseVersion_IsNotZero()
        {
            var file = new FileContract {
                Url = "https://protonvpn.com/download.exe", Sha1CheckSum = "012345", Arguments = "-install"
            };
            var contract = new ReleaseContract {
                Version = "0.0.1", ChangeLog = new[] { "Fixed" }, File = file
            };
            var release = new Release(contract, false, new Version());

            var result = release.Empty();

            result.Should().BeFalse();
        }
示例#2
0
        public void Version_ShouldBe_Release_Version()
        {
            var contract = new ReleaseContract {
                Version = "3.2.1"
            };
            var release = new Release(contract, false, new Version());

            var result = release.Version;

            result.Major.Should().Be(3);
            result.Minor.Should().Be(2);
            result.Build.Should().Be(1);
            result.Revision.Should().Be(-1);
        }