Sha256: 46dbe882b4d256569efc74855b6a9e7417d3598ac7572db40d96e488b84cfe2a

Contents?: true

Size: 374 Bytes

Versions: 8

Compression:

Stored size: 374 Bytes

Contents

module Quarto
	module FileMatchers
		class ExistOnDisk
			def matches?(target)
				@target = File.expand_path(target)
				File.exists?(@target)
			end
			
			def failure_message
				"Expected file #{@target} to exist"
			end
			
			def negative_failure_message
				"Expected file #{@target} not to exist"
			end
		end
		
		def exist_on_disk
			ExistOnDisk.new
		end
	end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
jarrett-quarto-1.4.0 spec/matchers/file_matchers.rb
jarrett-quarto-1.4.1 spec/matchers/file_matchers.rb
jarrett-quarto-1.5.0 spec/matchers/file_matchers.rb
jarrett-quarto-1.5.1 spec/matchers/file_matchers.rb
jarrett-quarto-1.6.0 spec/matchers/file_matchers.rb
jarrett-quarto-1.6.1 spec/matchers/file_matchers.rb
jarrett-quarto-1.6.2 spec/matchers/file_matchers.rb
jarrett-quarto-1.6.3 spec/matchers/file_matchers.rb