public void TestValidateInvalidFile() { var opts = new Options { BSPPath = "testdata/invalidFile.bsp" }; Assert.Throws <App.InvalidOptionException>(() => Program.ValidateOptions(opts)); }
public void TestValidateValidOptions() { var opts = new Options { BSPPath = "testdata/map.bsp", LumpIndex = 1 }; Program.ValidateOptions(opts); // Should not throw anything }
public void TestValidateInvalidLump() { var opts = new Options { BSPPath = "testdata/map.bsp", LumpIndex = -1 }; Assert.Throws <App.InvalidOptionException>(() => Program.ValidateOptions(opts)); opts.LumpIndex = 64; Assert.Throws <App.InvalidOptionException>(() => Program.ValidateOptions(opts)); }