Sha256: 1061fb99ecd74809b7624ba09c4ae0ff88b8126385c47caf69629aa0807a9ccf

Contents?: true

Size: 352 Bytes

Versions: 3

Compression:

Stored size: 352 Bytes

Contents

RSpec::Matchers.define :have_linux_line_endings do
  match do |file|
    !file.content.include?("\r\n")
  end

  failure_message do |file|
    "Expected file '#{file.name}' to have linux line endings, but it didn't"
  end

  failure_message_when_negated do |file|
    "Expected file '#{file.name}' to not have linux line endings, but it did"
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
octopus-serverspec-extensions-0.19.1 lib/octopus_serverspec_extensions/matcher/have_linux_line_endings.rb
octopus-serverspec-extensions-0.19.0 lib/octopus_serverspec_extensions/matcher/have_linux_line_endings.rb
octopus-serverspec-extensions-0.14.0 lib/octopus_serverspec_extensions/matcher/have_linux_line_endings.rb