Exemplo n.º 1
0
        public void testSetDestination()
        {
            RefSpec a = new RefSpec();
            RefSpec b = a.SetDestination("refs/heads/master");

            Assert.AreNotSame(a, b);
            Assert.AreEqual("HEAD", a.ToString());
            Assert.AreEqual("HEAD:refs/heads/master", b.ToString());
        }
Exemplo n.º 2
0
        public void testSetDestination_SourceNull()
        {
            RefSpec a = new RefSpec();
            RefSpec b;

            b = a.SetDestination("refs/heads/master");
            b = b.SetSource(null);
            Assert.AreNotSame(a, b);
            Assert.AreEqual("HEAD", a.ToString());
            Assert.AreEqual(":refs/heads/master", b.ToString());
        }