Esempio n. 1
0
        public void IsOlderThanClient_SameVersionOrAbove_False(string currentVersion)
        {
            var minimumVersion = "2019.11.0";

            ServerVersionCheck.IsOlderThanClient(currentVersion, SemanticVersion.Parse(minimumVersion))
            .Should().BeFalse();
        }
Esempio n. 2
0
        public void IsOlderThanClient_LowerVersion_True(string currentVersion)
        {
            var minimumVersion = "2019.11.0";

            ServerVersionCheck.IsOlderThanClient(currentVersion, SemanticVersion.Parse(minimumVersion))
            .Should().BeTrue();
        }
Esempio n. 3
0
        protected void EnsureServerIsMinimumVersion(SemanticVersion requiredVersion, Func <string, string> messageGenerator)
        {
            var currentServerVersion = Repository.LoadRootDocument().Version;

            if (ServerVersionCheck.IsOlderThanClient(currentServerVersion, requiredVersion))
            {
                throw new NotSupportedException(messageGenerator(currentServerVersion));
            }
        }
Esempio n. 4
0
 public void IsOlderThanClient_Development_False()
 {
     ServerVersionCheck.IsOlderThanClient("0.0.0-local", SemanticVersion.Parse("2019.11.0"))
     .Should().BeFalse();
 }