コード例 #1
0
 public void CanCreateBaseDescription()
 {
     var desc = new ProjectDescription("a", "b", "c");
     desc.Directory.Should().Be("a");
     desc.ProjectFile.Should().Be("b");
     desc.Assembly.Should().Be("c");
 }
コード例 #2
0
        public ProjectDescription WithName(string name)
        {
            var newProject = new ProjectDescription(
                Directory.AsFormat(name),
                ProjectFile.AsFormat(name),
                Assembly.AsFormat(name));
            newProject.Name = name;

            return newProject;
        }
コード例 #3
0
        public void CanCreateDerivedDescription()
        {
            var desc = new ProjectDescription("a{0}", "b{0}", "c{0}");
            var desc2 = desc.WithName("123");

            desc2.Should().Not.Be.SameInstanceAs(desc);
            desc2.Directory.Should().Be("a123");
            desc2.ProjectFile.Should().Be("b123");
            desc2.Assembly.Should().Be("c123");
        }