public void TestGeneralFileDropperCoreToPackage() { var projectFileDropperPackageToCore = new ProjectFileDropper(options, projectPathConverter); projectFileDropperPackageToCore.Run(); // Directory.Delete(Path.Combine(options.packageRootPath, "PackageDirectory"), true); var opt = options; opt.syncCoreToPackage = true; var projectFileDropperCoreToPackage = new ProjectFileDropper(opt, projectPathConverter); projectFileDropperCoreToPackage.Run(); var testClassDestPath = Path.Combine(options.packageRootPath, "PackageDirectory/Test.cs"); Assert.IsTrue(File.Exists(testClassDestPath)); var testDeepClassDestPath = Path.Combine(options.packageRootPath, "PackageDirectory/DeepDirectory/DeepFile.cs"); Assert.IsTrue(File.Exists(testDeepClassDestPath)); var manifestPath = Path.Combine(options.packageRootPath, "PackageDirectory/manifest.json"); Assert.IsTrue(File.Exists(manifestPath)); }
public void BlacklistWorksWithEndWith() { var projectFileDropperPackageToCore = new ProjectFileDropper(options, projectPathConverter); projectFileDropperPackageToCore.Run(); var metaFilePath = Path.Combine(options.coreRootPath, "CoreDirectory/DeepDirectory/ShouldNotBeCopied.cs.meta"); Assert.IsFalse(File.Exists(metaFilePath)); }
public void TestGeneralFileDropperPackageToCore() { // Directory.Delete(Path.Combine(options.coreRootPath, "CoreDirectory"), true); var projectFileDropper = new ProjectFileDropper(options, projectPathConverter); projectFileDropper.Run(); var testClassDestPath = Path.Combine(options.coreRootPath, "CoreDirectory/Test.cs"); Assert.IsTrue(File.Exists(testClassDestPath)); var testDeepClassDestPath = Path.Combine(options.coreRootPath, "CoreDirectory/DeepDirectory/DeepFile.cs"); Assert.IsTrue(File.Exists(testDeepClassDestPath)); var manifestPath = Path.Combine(options.coreRootPath, "CoreDirectory/manifest.json"); Assert.IsTrue(File.Exists(manifestPath)); Assert.IsFalse(IsPackageInManifest(manifestPath, "com.unity.ui")); }