pronto-rspec 0.0.1

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.
Files changed (5) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +3 -0
  4. data/lib/pronto/rspec.rb +27 -0
  5. metadata +107 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 7e39c57de36a5dce92f50ce01a1b836eec9f6262709de52b52aa2b749d9d59e7
4
+ data.tar.gz: 1acecb8c1c213df86314f3c02d7a67d437593dd6dcb7944555582310ffce3683
5
+ SHA512:
6
+ metadata.gz: 9f1de2c069d16a0304a6b759c503ff61cb40f005dd4d9a449870ff46b55832b0fe0c7887595519d27b1b0881900c21df8edebeec4266bc1de8614bdefc967e9e
7
+ data.tar.gz: 536e9d69b4d43455894873f7e995936dc73a122714aba3afc21890854114dc8ecfd1e18095f9ec99ae192f5a297150eb73896afdf3f46fc3bbeb35d2474e9919
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License
2
+
3
+ Copyright (c) 2019 Dazzl
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,3 @@
1
+ # Pronto runner for RSpec
2
+
3
+ Execute rspec for each spec file modify
@@ -0,0 +1,27 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'pronto'
4
+ require 'rspec'
5
+
6
+ module Pronto
7
+ # Runner RSpec with pronto
8
+ class Rspec < Runner
9
+ def run
10
+ files = ruby_patches.map(&:new_file_full_path)
11
+
12
+ return [] unless files
13
+
14
+ files.select { |file| valid_file?(file) }
15
+ .map { |file| inspect_file(file) }
16
+ .flatten.compact
17
+ end
18
+
19
+ def valid_file?(file)
20
+ file.file? && file.basename.to_s.include?('spec.rb')
21
+ end
22
+
23
+ def inspect_file(file)
24
+ exec("rspec #{file}")
25
+ end
26
+ end
27
+ end
metadata ADDED
@@ -0,0 +1,107 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: pronto-rspec
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - VAILLANT Jeremy
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2019-05-29 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: pry
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 0.12.2
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 0.12.2
27
+ - !ruby/object:Gem::Dependency
28
+ name: pronto
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: 0.10.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.10.0
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
55
+ description: " Search new/modified spec and execute this.\n"
56
+ email:
57
+ - jeremy@dazzl.tv
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files:
61
+ - LICENSE
62
+ - README.md
63
+ files:
64
+ - LICENSE
65
+ - README.md
66
+ - lib/pronto/rspec.rb
67
+ homepage: https://github.com/dazzl-tv/pronto-rpsec
68
+ licenses:
69
+ - MIT
70
+ metadata: {}
71
+ post_install_message: |-
72
+ # ====================================================== #
73
+ # Thanks for installing Pronto RSpec ! #
74
+ # https://github.com/dazzl-tv/pronto-rpsec. #
75
+ # ;;;;;;;;;;;:. #
76
+ # ;;;;;;;;;;;;;;;;;; #
77
+ # ;;;;;;;;;;;:;;;;;;;; #
78
+ # ;;;;;;;;;;` ;;;;;;;; #
79
+ # ;;;;;;;;; :;;;;;;;;. #
80
+ # ;;;;;;;; :::::;;;;; #
81
+ # ;;;;;;, ,;;;;;; #
82
+ # ;;;;; ;;;;;;;; #
83
+ # ;;;;;;;;; ;;;;;;;;, #
84
+ # ;;;;;;;;; `;;;;;;;;; A ZZZZZZZ ZZZZZZZ LL #
85
+ # ;;;;;;;;.:;;;;;;;;;; A A ZZZ ZZZ LL #
86
+ # ;;;;;;;;;;;;;;;;; AAAAA ZZ ZZ LL #
87
+ # ;;;;;;;;;;;;;, A A ZZZZZZZ ZZZZZZZ LLLLLLL #
88
+ # ====================================================== #
89
+ rdoc_options: []
90
+ require_paths:
91
+ - lib
92
+ required_ruby_version: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ required_rubygems_version: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - ">="
100
+ - !ruby/object:Gem::Version
101
+ version: '0'
102
+ requirements: []
103
+ rubygems_version: 3.0.3
104
+ signing_key:
105
+ specification_version: 4
106
+ summary: Runner for pronto
107
+ test_files: []