diff --git a/spec/page/screenshot_spec.rb b/spec/page/screenshot_spec.rb index 8442cbe8..8ea64a06 100644 --- a/spec/page/screenshot_spec.rb +++ b/spec/page/screenshot_spec.rb @@ -145,7 +145,7 @@ def create_screenshot(**options) browser.screenshot(path: file, quality: 0) # ignored for png browser.screenshot(path: file2) # defaults to a quality of 75 browser.screenshot(path: file3, quality: 100) - expect(File.size(file)).to be > File.size(file2) # png by default is bigger + expect(File.size(file)).to be < File.size(file2) # png by default is lighter expect(File.size(file2)).to be < File.size(file3) ensure FileUtils.rm_f([file2, file3])