コード例 #1
0
            public void Should_Throw_If_Format_For_LogFileContent_Is_Null()
            {
                // Given
                var logFileContent = "foo".ToByteArray();
                BaseMarkdownlintLogFileFormat format = null;

                // When
                var result = Record.Exception(() =>
                                              new MarkdownlintIssuesSettings(logFileContent, format));

                // Then
                result.IsArgumentNullException("format");
            }
コード例 #2
0
            public void Should_Throw_If_Format_For_LogFilePath_Is_Null()
            {
                // Given
                BaseMarkdownlintLogFileFormat format = null;

                using (var tempFile = new ResourceTempFile("Cake.Issues.Markdownlint.Tests.Testfiles.MarkdownlintLogFileFormat.markdownlint.json"))
                {
                    // When
                    var result = Record.Exception(() =>
                                                  new MarkdownlintIssuesSettings(tempFile.FileName, format));

                    // Then
                    result.IsArgumentNullException("format");
                }
            }