Exemple #1
0
        public void AbleToCrateAndDeleteBranch()
        {
            const string testBranchName = "subproduct/testFeature";
            var          newBranch      = gitlabClient.CreateBranch(testBranchName, "release");

            Assert.IsNotNull(newBranch);
            Assert.AreEqual(newBranch.Name, testBranchName);

            gitlabClient.DeleteBranch(testBranchName);
            var actualBranches = gitlabClient.SelectAllBranches();

            Assert.AreEqual(0, actualBranches.Count(b => b.Name.Equals(testBranchName)));
        }
Exemple #2
0
        public void AbleToSelectBranches()
        {
            var allBranches = gitlabClient.SelectAllBranches();

            Assert.True(allBranches.Length > 2);
            var releaseBranch = allBranches.FirstOrDefault(x => x.Name == "release");

            Assert.IsNotNull(releaseBranch);
            Assert.IsNotNull(releaseBranch.Commit);
            Assert.IsNotNull(releaseBranch.Commit.Id);
            Assert.IsNotNull(releaseBranch.Commit.Message);
            Assert.IsNotNull(releaseBranch.Commit.Committer_name);
            Assert.IsNotNull(releaseBranch.Commit.Committer_email);
            Assert.IsNotNull(releaseBranch.Commit.Committed_date);
        }
Exemple #3
0
        public void AbleToFindLastCommitAtBranch()
        {
            var lastCommits = gitlabClient.SelectLastCommits("release", 1, 100);

            Assert.True(lastCommits.Length == 100);
            var lastCommit = lastCommits.First();

            Assert.IsNotNull(lastCommit.Id);
            Assert.IsNotNull(lastCommit.Short_id);
            Assert.IsNotNull(lastCommit.Title);
            Assert.IsNotNull(lastCommit.Message);
            Assert.IsNotNull(lastCommit.Author_email);
            Assert.IsNotNull(lastCommit.Author_name);
            Assert.IsNotNull(lastCommit.Created_at);
        }
Exemple #4
0
        public void ItCanLoadParticularCard()
        {
            var actual = trelloClient.GetCard("lpDZvlGm");

            Assert.IsNotNull(actual);
        }