prism_checker_rspec 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 93150aee88e9f14b51be0834f10644d565012ad352d0e1bb0be00ffe65c1007a
4
+ data.tar.gz: c82481bbc0eb309be7e21f37f37639bc5780a8b31063863f4fb7283028bcb80a
5
+ SHA512:
6
+ metadata.gz: a13671613db42f2926340b4e0c132d5ec6ac423a32905a45eb6ccaf6cede93403f11f8f06b46002b94be7cdf629cda88d609898dc6541828e241c1096ea1cd12
7
+ data.tar.gz: fb8512779d5fb61c62775d11c4e33e8e508b069da89f3979c7510aa1d17cbb79d65f661c5de7f6c701d29278010a9a0de52cc8f5a2d206e1d68bedc7a00c5e23
data/LICENSE.md ADDED
@@ -0,0 +1,28 @@
1
+ Copyright (c) 2011-2021, The SitePrism team
2
+
3
+ All rights reserved.
4
+
5
+ Redistribution and use in source and binary forms, with or without
6
+ modification, are permitted provided that the following conditions are met:
7
+
8
+ 1. Redistributions of source code must retain the above copyright notice,
9
+ this list of conditions and the following disclaimer.
10
+
11
+ 2. Redistributions in binary form must reproduce the above copyright
12
+ notice, this list of conditions and the following disclaimer in the
13
+ documentation and/or other materials provided with the distribution.
14
+
15
+ 3. Neither the name of the copyright holder nor the names of its contributors
16
+ may be used to endorse or promote products derived from this software without
17
+ specific prior written permission.
18
+
19
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21
+ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
22
+ IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
23
+ INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
24
+ NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
25
+ OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
26
+ WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27
+ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28
+ POSSIBILITY OF SUCH DAMAGE.
data/README.md ADDED
@@ -0,0 +1,3 @@
1
+ # PrismCheckerRspec
2
+
3
+ Please visit [prism_checker](https://github.com/prism-checker/prism_checker)
data/lib/colorizer.rb ADDED
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ module PrismCheckerRspec
4
+ class Colorizer
5
+ def self.colorize(text, code)
6
+ RSpec::Core::Formatters::ConsoleCodes.wrap(text, code)
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,17 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'prism_checker'
4
+ require 'colorizer'
5
+
6
+ RSpec::Matchers.define(:be_like) do |expected|
7
+ checker = PrismChecker::Checker.new
8
+ PrismChecker.colorizer = PrismCheckerRspec::Colorizer
9
+
10
+ match do |actual|
11
+ checker.check(actual, expected)
12
+ end
13
+
14
+ failure_message do |_actual|
15
+ checker.report
16
+ end
17
+ end
metadata ADDED
@@ -0,0 +1,77 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: prism_checker_rspec
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.2
5
+ platform: ruby
6
+ authors:
7
+ - Ganglion-17
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2024-01-30 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rspec
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: prism_checker
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ description: |
42
+ Prism checker is an extension for rspec and minitest, built on top of the SitePrism gem and using its page object model.
43
+ It allows you to write short, easy-to-read browser tests with clear error messages
44
+ email:
45
+ - ganglion1717@gmail.com
46
+ executables: []
47
+ extensions: []
48
+ extra_rdoc_files: []
49
+ files:
50
+ - LICENSE.md
51
+ - README.md
52
+ - lib/colorizer.rb
53
+ - lib/prism_checker_rspec.rb
54
+ homepage: https://github.com/prism-checker/prism_checker_rspec
55
+ licenses:
56
+ - BSD-3-Clause
57
+ metadata: {}
58
+ post_install_message:
59
+ rdoc_options: []
60
+ require_paths:
61
+ - lib
62
+ required_ruby_version: !ruby/object:Gem::Requirement
63
+ requirements:
64
+ - - ">="
65
+ - !ruby/object:Gem::Version
66
+ version: 2.5.0
67
+ required_rubygems_version: !ruby/object:Gem::Requirement
68
+ requirements:
69
+ - - ">="
70
+ - !ruby/object:Gem::Version
71
+ version: '0'
72
+ requirements: []
73
+ rubygems_version: 3.1.4
74
+ signing_key:
75
+ specification_version: 4
76
+ summary: Short and easy-to-read browser tests with clear error messages. Rspec wrapper
77
+ test_files: []