snapshot_testing 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3ee6e9be24d834327777882a006b5fedfb21e6bc80742aecff6d5019afa89b36
4
- data.tar.gz: cf39e0f6ad48dda7595d73119b4ff90d815b64cbd032a339e31ad2518882984a
3
+ metadata.gz: 26bd438aaed8bb5b446ab754e9cf1cc68f4ec69c85b90686c10d1c704231c036
4
+ data.tar.gz: dd2e8a207d362121cd158dda69b71b80e2542377634daf26f7c9cb69c319b29f
5
5
  SHA512:
6
- metadata.gz: 7d37c954cec8d655723344877db157cf4323e4ac945dcd03e6f1ca503f82afdaea7bd1b693ca5f1d96a129604c3ea27e663381eb655220d215c636bf7eec8c8b
7
- data.tar.gz: bac21cb8bdd3041502102f4024815a2d10b1abe0021042c02fe2fdf0698736e1d7f7078846594a3445ea6f5c6f9872779e54b4c40c845e945032c0ee7a9068f1
6
+ metadata.gz: 2a4b44606c27cfada6173f539e7f2614b725d03bb6a3c79ec3602073860bcc690612a1f6d0061438894529b218a8d2aaa87f041e1a085f1ddeb49582a8bc3c73
7
+ data.tar.gz: 85fc59d0aa33d4a0e0726c563e36756ab55a4c6bfa36888e731ebf268a68c987adf649600470ebd443b76f92bbde1ed98e2891519639c72281fc4f91920f20b3
@@ -1,15 +1,15 @@
1
- snapshots["test_0001_takes a snapshot 1"] = <<~SNAP
1
+ snapshots["test_0001_takes a snapshot 1"] = <<-SNAP
2
2
  hello
3
3
  SNAP
4
4
 
5
- snapshots["test_0001_takes a snapshot 2"] = <<~SNAP
5
+ snapshots["test_0001_takes a snapshot 2"] = <<-SNAP
6
6
  goodbye
7
7
  SNAP
8
8
 
9
- snapshots["test_snapshot 1"] = <<~SNAP
9
+ snapshots["test_snapshot 1"] = <<-SNAP
10
10
  hello
11
11
  SNAP
12
12
 
13
- snapshots["test_snapshot 2"] = <<~SNAP
13
+ snapshots["test_snapshot 2"] = <<-SNAP
14
14
  goodbye
15
15
  SNAP
@@ -1,7 +1,7 @@
1
- snapshots["takes a snapshot 1"] = <<~SNAP
1
+ snapshots["takes a snapshot 1"] = <<-SNAP
2
2
  hello
3
3
  SNAP
4
4
 
5
- snapshots["takes a snapshot 2"] = <<~SNAP
5
+ snapshots["takes a snapshot 2"] = <<-SNAP
6
6
  goodbye
7
7
  SNAP
@@ -1,7 +1,7 @@
1
- snapshots["test_snapshot 1"] = <<~SNAP
1
+ snapshots["test_snapshot 1"] = <<-SNAP
2
2
  hello
3
3
  SNAP
4
4
 
5
- snapshots["test_snapshot 2"] = <<~SNAP
5
+ snapshots["test_snapshot 2"] = <<-SNAP
6
6
  goodbye
7
7
  SNAP
@@ -1,5 +1,4 @@
1
1
  require "fileutils"
2
- require "pastel"
3
2
 
4
3
  module SnapshotTesting
5
4
  class Recorder
@@ -65,7 +64,13 @@ module SnapshotTesting
65
64
  def log(count, status, color)
66
65
  label = count == 1 ? "snapshot" : "snapshots"
67
66
  message = "#{count} #{label} #{status}."
68
- warn Pastel.new.public_send(color, message)
67
+
68
+ case color
69
+ when :yellow
70
+ warn "\e[33m#{message}\e[0m"
71
+ when :green
72
+ warn "\e[32m#{message}\e[0m"
73
+ end
69
74
  end
70
75
 
71
76
  def write(snapshots)
@@ -1,3 +1,3 @@
1
1
  module SnapshotTesting
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
@@ -23,7 +23,6 @@ Gem::Specification.new do |spec|
23
23
 
24
24
  spec.required_ruby_version = '>= 2.4.0'
25
25
 
26
- spec.add_dependency "pastel", "~> 0.7"
27
26
  spec.add_development_dependency "bundler", "~> 2.0"
28
27
  spec.add_development_dependency "rake", "~> 10.0"
29
28
  spec.add_development_dependency "rspec", "~> 3.0"
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: snapshot_testing
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ray Zane
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-07-07 00:00:00.000000000 Z
11
+ date: 2019-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: pastel
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '0.7'
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '0.7'
27
13
  - !ruby/object:Gem::Dependency
28
14
  name: bundler
29
15
  requirement: !ruby/object:Gem::Requirement