public void Should_Throw_If_Path_Is_Null()
            {
                // Given
                var settings = new LibManInstallSettings();

                // When
                var result = Record.Exception(() => settings.FromPath(null));

                // Then
                result.IsArgumentNullException("path");
            }
            public void Should_Set_WorkingDirectory()
            {
                // Given
                var settings = new LibManInstallSettings();

                // When
                settings.FromPath(@"c:\temp");

                // Then
                settings.WorkingDirectory.ToString().ShouldBe(@"c:/temp");
            }
            public void Should_Set_LogLevel(LibManVerbosity verbosity)
            {
                // Given
                var settings = new LibManInstallSettings();

                // When
                settings.WithVerbosity(verbosity);

                // Then
                settings.Verbosity.ShouldBe(verbosity);
            }
        public static void LibManInstall(this ICakeContext context, Action <LibManInstallSettings> configurator)
        {
            if (context == null)
            {
                throw new ArgumentNullException(nameof(context));
            }

            if (configurator == null)
            {
                throw new ArgumentNullException(nameof(configurator));
            }

            var settings = new LibManInstallSettings();

            configurator(settings);
            context.LibManInstall(settings);
        }
        public static void LibManInstall(this ICakeContext context, LibManInstallSettings settings)
        {
            if (context == null)
            {
                throw new ArgumentNullException(nameof(context));
            }

            if (settings == null)
            {
                throw new ArgumentNullException(nameof(settings));
            }

            LibManAddinInformation.LogVersionInformation(context.Log);
            var installer = new LibManInstaller(context.FileSystem, context.Environment, context.ProcessRunner, context.Tools, context.Log);

            installer.Install(settings);
        }