rspec-visual 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a003cdbec4d7284cec1419b7f6b4bca7c516bb62
4
- data.tar.gz: 75a4ee1e612612454829ec7677aa340c4810112b
3
+ metadata.gz: b47a315c90006f7fc9f51fbe940fa49979846a5c
4
+ data.tar.gz: ccef70dcb82d052e1189f5fd212501417698eb99
5
5
  SHA512:
6
- metadata.gz: e7756763e7f83749b41ca5e9e2755138785cd6af2990bee75c47c4452afab6f9fae1effe5bb10b7dc0393c31dd9ea6a16f6dd5707faa18de486c3a4deb683aad
7
- data.tar.gz: 8141f2ab42372d477dbbf5d8f48f9da262c449ce9639d38bf630faa79e1440a823bd78f62f43de8cd25f90517bc3f4583c5a411afc55db0a1a88ecf85af3b2dc
6
+ metadata.gz: 9d8788d6092a270a25ce7adabf7a70566fdb98b5f98c6fe18608b315dd3bbe738e53fd25e95848e4bd64fd318c7c05117c846f78d7a130aa15185849de1fb4d5
7
+ data.tar.gz: 17d154ccfc88329e2a1abe32e12bfe1de9110d216cab701f2a9a4f8c39a28a6a7a6fefe929c442c10c197f641ca623c5669e6e3463c0c483160e9bf249d9f750
@@ -1,4 +1,6 @@
1
1
  require 'singleton'
2
+ require 'capybara/rspec'
3
+ require 'capybara/poltergeist'
2
4
 
3
5
  module Rspec
4
6
  module Visual
@@ -1,5 +1,6 @@
1
1
  require 'rspec'
2
2
  require 'rspec/expectations'
3
+ require 'fileutils'
3
4
 
4
5
  RSpec::Matchers.define :look_like do |expected|
5
6
  expected_image_file_path = File.join(Rspec::Visual::Configuration.stable_screenshot_folder, "#{expected}.png")
@@ -7,7 +8,7 @@ RSpec::Matchers.define :look_like do |expected|
7
8
 
8
9
  match do |actual|
9
10
  unless File.exists?(expected_image_file_path)
10
- File.cp(actual_image_file_path, expected_image_file_path) and return true
11
+ FileUtils.cp(actual_image_file_path, expected_image_file_path) and return true
11
12
  end
12
13
 
13
14
  diff_file_path = File.join(Rspec::Visual::Configuration.screenshot_folder, "#{expected}_diff.png")
@@ -1,5 +1,5 @@
1
1
  module Rspec
2
2
  module Visual
3
- VERSION = "0.0.1"
3
+ VERSION = "0.0.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-visual
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Simon Bagreev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-18 00:00:00.000000000 Z
11
+ date: 2015-09-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec