Exemplo n.º 1
0
        public void Get_all_content_for_asset_using_a_test_processor()
        {
            AssetPipeline.Processors.Add(new TestAssetProcessor());

            var target = new AssetLoader(_lookupDirectories);
            var content = target.GetContent("test1.a.js");
            Assert.AreEqual("AA", content);
        }
Exemplo n.º 2
0
        public void Get_all_content_for_asset()
        {
            var target = new AssetLoader(_lookupDirectories);
            var content = target.GetContent("test1.b.js");
            var expectedResult =
            @"var test1_b = """";
            var test1_1_a = """";
            var test1_1_1_a = """";
            var test1_1_1_b = """";
            var test1_2_a = """";
            var test1_2_b = """";";

            Assert.AreEqual(expectedResult, content.Trim());
        }
Exemplo n.º 3
0
 public void Get_all_content_for_asset_which_contains_coffeescript()
 {
     var target = new AssetLoader(_lookupDirectories);
     var content = target.GetContent("test2.a.js");
     Assert.AreEqual("var test;\ntest = 5;", content.Trim());
 }
Exemplo n.º 4
0
 public void Get_all_content_for_asset_containing_require_self()
 {
     var target = new AssetLoader(_lookupDirectories);
     var content = target.GetContent("test1.a.js");
     Assert.AreEqual("var test1_1_1_a = \"\";var test1_a = \"\";", content.Trim().Replace("\n", "").Replace("\r", ""));
 }