예제 #1
0
        public void FindInProjectNotsconfig()
        {
            string  projectFullName = Path.GetFullPath(@"../../artifacts/tsconfig/none/tsconfigEmptyTest.csproj");
            Project project         = FindProject(projectFullName, solution);

            Tsconfig[] results = TsconfigLocations.FindInProject(project).ToArray();
            Assert.IsNotNull(results);
            Assert.AreEqual(0, results.Length);
        }
예제 #2
0
        public void FindInProject()
        {
            string  projectFullName = Path.GetFullPath(@"../../artifacts/tsconfig/multiple/tsconfigTest.csproj");
            Project project         = FindProject(projectFullName, solution);

            Tsconfig[] results   = TsconfigLocations.FindInProject(project).ToArray();
            string     expected1 = Path.GetFullPath(@"../../artifacts/tsconfig/multiple/tsconfig.json");
            string     expected2 = Path.GetFullPath(@"../../artifacts/tsconfig/multiple/a/tsconfig.json");
            string     expected3 = Path.GetFullPath(@"../../artifacts/tsconfig/multiple/b/tsconfig.json");

            Assert.AreEqual(3, results.Length);
            Assert.IsTrue(Contains(results, expected1));
            Assert.IsTrue(Contains(results, expected2));
            Assert.IsTrue(Contains(results, expected3));
        }