public void Export() { // Assign var outputPath = Path.Combine(TestContext.DeploymentDirectory, "Test.xls"); if( File.Exists(outputPath)) { File.Delete(outputPath); } var exporter = new ResourceExport(TestContext.DeploymentDirectory, "en", outputPath); // Act exporter.Export(); // Assert Assert.IsTrue(File.Exists(outputPath)); }
static void Main(string[] args) { var options = new CommandLineOptions(); ICommandLineParser parser = new CommandLineParser(); if (parser.ParseArguments(args, options, Console.Out)) { if (options.Export) { var export = new ResourceExport(options.InputDirectory, options.Language, options.XlsFile); export.Export(); } else { var importer = new ResourceImport(options.XlsFile, options.Language, options.InputDirectory); importer.Import(); } } }