コード例 #1
0
        public void SetsPort()
        {
            var processor = new SetOptions(null, null, "12345", null);
            var args      = new StartMongoDbArgs();

            processor.Process(args);
            args.Port.Value.Should().Be(12345);
        }
コード例 #2
0
        public void SetsExePath()
        {
            var processor = new SetOptions("exe path", null, null, null);
            var args      = new StartMongoDbArgs();

            processor.Process(args);
            args.ExePath.Should().Be("exe path");
        }
コード例 #3
0
        public void SetsAdditionalArgs()
        {
            var processor = new SetOptions(null, null, null, "additional args");
            var args      = new StartMongoDbArgs();

            processor.Process(args);
            args.AdditionalArgs.Should().Be("additional args");
        }
コード例 #4
0
        public void SetsDbPath()
        {
            var processor = new SetOptions(null, "db path", null, null);
            var args      = new StartMongoDbArgs();

            processor.Process(args);
            args.DbFolderPath.Should().Be("db path");
        }
コード例 #5
0
        public void LeavesPreviousPortValueWhenNotSupplied()
        {
            var processor = new SetOptions(null, null, "", null);
            var args      = new StartMongoDbArgs()
            {
                Port = 12345
            };

            processor.Process(args);
            args.Port.Value.Should().Be(12345);
        }