コード例 #1
0
        public void MessageContainsCommand(string command)
        {
            // Act
            var sut = new DockerCommandException(command, new string[0]);

            // Assert
            sut.Message.Should().Contain($"Command: {command}{Environment.NewLine}");
        }
コード例 #2
0
        public void MessageContainsOutput()
        {
            // Arrange
            var output = new[]
            {
                "output1",
                string.Empty,
                null,
                "/t",
                "output4"
            };

            // Act
            var sut = new DockerCommandException("test command", output);

            // Assert
            sut.Message.Should().Contain($"Process Output:{Environment.NewLine}{string.Join(Environment.NewLine, output)}");
        }
コード例 #3
0
 protected override void ErrorAction(DockerCommandException e) => throw new DockerContainerNotFoundException(Id, e);
コード例 #4
0
ファイル: DockerEntity.cs プロジェクト: matt-jenner/dockhand
 protected virtual void ErrorAction(DockerCommandException e) => throw new NotImplementedException();