static void Main(string[] args) { string filePath = Environment.ExpandEnvironmentVariables(UserSettings.Default.ProfileFileLocation); string directoryPath = Path.GetDirectoryName(filePath); if (!Directory.Exists(directoryPath)) { Directory.CreateDirectory(directoryPath); } IProfileStore store = new StreamProfileStore( new FileStream(filePath, FileMode.OpenOrCreate), new XMLProfileEncoder()); _handler.RegisterResource <IProfileStore>(store) .RegisterTypeConverter <IPAddress>(s => IPAddress.Parse(s)) .RegisterResource <IProfileApplier>(new ProfileApplier()) .RegisterResource <IUserSettings>(new DefaultUserSettings()); _handler.Handle(args); }
static void Main(string[] args) { CLImberConfig(); _handler.Handle(args); }
public void Handle_ShouldFindClassesInAssembly_WhenDecoratedWithCommandClass() { string[] arguments = { "test_command" }; _sut.Handle(arguments); DummyCommand.CallCount.Should().Be(1); }