Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

spec markdown lint tests fail with mdl >= 0.12 #386

Open
kienanstewart opened this issue Feb 4, 2024 · 0 comments
Open

spec markdown lint tests fail with mdl >= 0.12 #386

kienanstewart opened this issue Feb 4, 2024 · 0 comments
Labels

Comments

@kienanstewart
Copy link

Describe the Bug

When using mdl >= 0.12, the spec tests in spec/unit/puppet-strings/markdown_spec.rb fail as follows:

Failures:                                                                                                                                             
                                                                                                                                                      
  1) PuppetStrings::Markdown rendering fixtures does not generate markdown lint errors from the rendered markdown                                     
     Failure/Error: expect(output).to have_no_markdown_lint_errors                                                                                    
       expected that "# Reference\n\n<!-- DO NOT EDIT: This document was generated by Puppet Strings -->"... would have no markdown lint errors but go
t 593: MD012 Multiple consecutive blank lines:                                                                                                        
     Shared Example Group: "markdown lint checker" called from ./spec/unit/puppet-strings/markdown_spec.rb:56                                         
     # ./spec/unit/puppet-strings/markdown_spec.rb:48:in `block (4 levels) in <top (required)>'                                                       
                                                                                                                                                      
  2) PuppetStrings::Markdown rendering fixtures with Puppet Plans does not generate markdown lint errors from the rendered markdown                   
     Failure/Error: expect(output).to have_no_markdown_lint_errors                                                                                    
       expected that "# Reference\n\n<!-- DO NOT EDIT: This document was generated by Puppet Strings -->"... would have no markdown lint errors but go
t 631: MD012 Multiple consecutive blank lines:                                                                                                        
     Shared Example Group: "markdown lint checker" called from ./spec/unit/puppet-strings/markdown_spec.rb:105                                        
     # ./spec/unit/puppet-strings/markdown_spec.rb:48:in `block (4 levels) in <top (required)>'                                                       
                                                                                                                                                      
  3) PuppetStrings::Markdown rendering fixtures with Puppet Data Types does not generate markdown lint errors from the rendered markdown
     Failure/Error: expect(output).to have_no_markdown_lint_errors      
       expected that "# Reference\n\n<!-- DO NOT EDIT: This document was generated by Puppet Strings -->"... would have no markdown lint errors but go
t 669: MD012 Multiple consecutive blank lines: 
     Shared Example Group: "markdown lint checker" called from ./spec/unit/puppet-strings/markdown_spec.rb:119
     # ./spec/unit/puppet-strings/markdown_spec.rb:48:in `block (4 levels) in <top (required)>'

This is due to mdl changing the default indentation from 2 spaces to 3 spaces for the rule MD007. See markdownlint/markdownlint@67f8312

Expected Behavior

The rspec tests should pass.

Steps to Reproduce

  1. Clone puppet-strings 4.2.1
  2. Update the Gemfile temporarily to install mdl 0.12 or newer
  3. Update installed gems in bundle
  4. Use bundle to run the spec tests

Environment

  • Version: 4.2.1
  • OS: Debian sid
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant