rspeckled 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/lib/rspeckled/helpers/patterns.rb +0 -1
- data/lib/rspeckled/helpers/responses.rb +0 -3
- data/lib/rspeckled/plugins/bundler.rb +13 -0
- data/lib/rspeckled/plugins/capybara.rb +48 -0
- data/lib/rspeckled/plugins.rb +2 -0
- data/lib/rspeckled/spec_helpers/active_record_basic.rb +2 -1
- data/lib/rspeckled/spec_helpers/rails.rb +8 -0
- data/lib/rspeckled/spec_helpers/rails_engine.rb +1 -1
- data/lib/rspeckled/spec_helpers/rspeckled.rb +8 -0
- data/lib/rspeckled/support.rb +86 -1
- data/lib/rspeckled/version.rb +1 -1
- data/lib/rspeckled.rb +0 -8
- data.tar.gz.sig +0 -0
- metadata +7 -15
- metadata.gz.sig +2 -3
- data/lib/rspeckled/support/expectations.rb +0 -6
- data/lib/rspeckled/support/failures.rb +0 -5
- data/lib/rspeckled/support/focused.rb +0 -6
- data/lib/rspeckled/support/formatters.rb +0 -6
- data/lib/rspeckled/support/heroku.rb +0 -1
- data/lib/rspeckled/support/i18n.rb +0 -5
- data/lib/rspeckled/support/mocks.rb +0 -7
- data/lib/rspeckled/support/output.rb +0 -1
- data/lib/rspeckled/support/pending.rb +0 -3
- data/lib/rspeckled/support/rails.rb +0 -13
- data/lib/rspeckled/support/random.rb +0 -3
- data/lib/rspeckled/support/selenium.rb +0 -4
- /data/lib/rspeckled/{support → plugins}/garbage_collection.rb +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d7577e96b392051718ad64058a4f9cf5b71fd773
|
4
|
+
data.tar.gz: b642ee57a5a4d73d64646f56c7b0697e10fb7408
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 36fb1b28483ececb3e85200ab9ae50c76fd26bacb15a33b901e40c454c5e10398dc7166d15bfcf0085734b6723526926498babbc5701ab584d38e6600b33910f
|
7
|
+
data.tar.gz: a25bac8c8f33e4567100fe0945dca9261412452b1b590cb1d4731d5586cd0e19e0654336bf606be4995b9bc96c351386e42ed5f833122149cc816f6a1d31637a
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
@@ -0,0 +1,13 @@
|
|
1
|
+
##############################################################################
|
2
|
+
# Bundler
|
3
|
+
##############################################################################
|
4
|
+
#
|
5
|
+
# Stolen from http://myronmars.to/n/dev-blog/2012/03/faster-test-boot-times-with-bundler-standalone
|
6
|
+
#
|
7
|
+
begin
|
8
|
+
require File.join(Dir.pwd, 'bundle', 'bundler', 'setup.rb')
|
9
|
+
rescue LoadError
|
10
|
+
require 'bundler'
|
11
|
+
|
12
|
+
Bundler.setup
|
13
|
+
end
|
@@ -0,0 +1,48 @@
|
|
1
|
+
##############################################################################
|
2
|
+
# Capybara Plugin
|
3
|
+
##############################################################################
|
4
|
+
#
|
5
|
+
# This plugin does not attempt to require capybara. It assumes that if you're
|
6
|
+
# using capybara, you're probably using something like Bundler which has already
|
7
|
+
# required it for you.
|
8
|
+
#
|
9
|
+
# If this is not the case, you will need to require it prior to requiring
|
10
|
+
# rspeckled.
|
11
|
+
#
|
12
|
+
# The same goes for capybara-webkit. It must be required before rspeckled.
|
13
|
+
#
|
14
|
+
begin
|
15
|
+
require 'capybara/rspec'
|
16
|
+
require 'capybara/rails'
|
17
|
+
|
18
|
+
if defined?(Capybara::Driver::Base)
|
19
|
+
Capybara.register_driver :chrome do |app|
|
20
|
+
Capybara::Selenium::Driver.new(app, :browser => :chrome)
|
21
|
+
end
|
22
|
+
|
23
|
+
Capybara.javascript_driver = if defined?(Capybara::Webkit)
|
24
|
+
:webkit
|
25
|
+
else
|
26
|
+
:selenium
|
27
|
+
end
|
28
|
+
|
29
|
+
RSpec.configure do |config|
|
30
|
+
config.before(:each, :js => true) do
|
31
|
+
page.driver.reset!
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
Capybara.configure do |config|
|
36
|
+
config.match = :prefer_exact
|
37
|
+
config.ignore_hidden_elements = true
|
38
|
+
config.visible_text_only = true
|
39
|
+
end
|
40
|
+
|
41
|
+
if defined?(Chamber)
|
42
|
+
Capybara.default_host = Chamber.env.http.host_with_port
|
43
|
+
Capybara.app_host = Chamber.env.http.base_url
|
44
|
+
Capybara.server_port = Chamber.env.http.port
|
45
|
+
end
|
46
|
+
end
|
47
|
+
rescue LoadError
|
48
|
+
end
|
data/lib/rspeckled/plugins.rb
CHANGED
@@ -3,11 +3,13 @@ require 'rspeckled/plugins/authentication'
|
|
3
3
|
require 'rspeckled/plugins/awesome_print'
|
4
4
|
require 'rspeckled/plugins/bullet'
|
5
5
|
require 'rspeckled/plugins/carrier_wave'
|
6
|
+
require 'rspeckled/plugins/capybara'
|
6
7
|
require 'rspeckled/plugins/database_cleaner'
|
7
8
|
require 'rspeckled/plugins/devise'
|
8
9
|
require 'rspeckled/plugins/elasticsearch'
|
9
10
|
require 'rspeckled/plugins/email'
|
10
11
|
require 'rspeckled/plugins/factory_girl'
|
12
|
+
require 'rspeckled/plugins/garbage_collection'
|
11
13
|
require 'rspeckled/plugins/fakeredis'
|
12
14
|
require 'rspeckled/plugins/features'
|
13
15
|
require 'rspeckled/plugins/omniauth'
|
data/lib/rspeckled/support.rb
CHANGED
@@ -1 +1,86 @@
|
|
1
|
-
|
1
|
+
###
|
2
|
+
# If DATABASE_URL is set, it means we're in production and running the tests
|
3
|
+
# would be very bad news.
|
4
|
+
#
|
5
|
+
abort('DATABASE_URL environment variable is set') if ENV['DATABASE_URL']
|
6
|
+
|
7
|
+
RSpec.configure do |config|
|
8
|
+
##############################################################################
|
9
|
+
# RAILS
|
10
|
+
##############################################################################
|
11
|
+
|
12
|
+
if defined? RSpec::Rails
|
13
|
+
require 'rspeckled/plugins/rails/engine'
|
14
|
+
|
15
|
+
config.infer_base_class_for_anonymous_controllers = true
|
16
|
+
|
17
|
+
config.infer_spec_type_from_file_location! if config.respond_to?(:infer_spec_type_from_file_location!)
|
18
|
+
|
19
|
+
if Pathname.pwd.join('spec', 'dummy', 'config', 'environment.rb').exist?
|
20
|
+
config.include Rspeckled::NamespacedEngineControllerRouteFix, :type => :controller
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
##############################################################################
|
25
|
+
# MOCKING
|
26
|
+
##############################################################################
|
27
|
+
|
28
|
+
config.mock_with :rspec do |mocks|
|
29
|
+
mocks.verify_partial_doubles = true
|
30
|
+
mocks.verify_doubled_constant_names = true
|
31
|
+
mocks.syntax = :expect
|
32
|
+
end
|
33
|
+
|
34
|
+
##############################################################################
|
35
|
+
# INTERNATIONALIZATION
|
36
|
+
##############################################################################
|
37
|
+
|
38
|
+
if defined? AbstractController::Translation
|
39
|
+
config.include AbstractController::Translation
|
40
|
+
end
|
41
|
+
|
42
|
+
##############################################################################
|
43
|
+
# FORMATTING
|
44
|
+
##############################################################################
|
45
|
+
|
46
|
+
config.color = true
|
47
|
+
|
48
|
+
config.add_formatter 'Fuubar'
|
49
|
+
config.add_formatter 'documentation', 'tmp/rspec.txt'
|
50
|
+
|
51
|
+
##############################################################################
|
52
|
+
# FILTERING AND RUN ORDER
|
53
|
+
##############################################################################
|
54
|
+
|
55
|
+
# Pending Specs
|
56
|
+
config.alias_example_to :pit, :pending => true
|
57
|
+
|
58
|
+
# Focused Specs
|
59
|
+
config.filter_run :focused => true
|
60
|
+
config.alias_example_to :fit, :focused => true
|
61
|
+
|
62
|
+
# Focus and Force Selenium
|
63
|
+
config.alias_example_to :sit, :focused => true,
|
64
|
+
:js => true,
|
65
|
+
:driver => :selenium
|
66
|
+
|
67
|
+
config.order = 'random'
|
68
|
+
config.run_all_when_everything_filtered = true
|
69
|
+
|
70
|
+
##############################################################################
|
71
|
+
# PERSISTENT FAILURES
|
72
|
+
##############################################################################
|
73
|
+
|
74
|
+
if config.respond_to?(:example_status_persistence_file_path=)
|
75
|
+
config.example_status_persistence_file_path = 'tmp/rspec_examples.txt'
|
76
|
+
end
|
77
|
+
|
78
|
+
##############################################################################
|
79
|
+
# EXPECTATIONS
|
80
|
+
##############################################################################
|
81
|
+
|
82
|
+
config.expect_with :rspec do |c|
|
83
|
+
c.syntax = :expect
|
84
|
+
c.include_chain_clauses_in_custom_matcher_descriptions = true
|
85
|
+
end
|
86
|
+
end
|
data/lib/rspeckled/version.rb
CHANGED
data/lib/rspeckled.rb
CHANGED
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rspeckled
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- thegranddesign
|
@@ -31,7 +31,7 @@ cert_chain:
|
|
31
31
|
zRIv8lqQM8QFT76rzP5SBCERwN+ltKAFbQ5/FwmZNGWYnmCP3RZMQiRnbh+9H9lh
|
32
32
|
mlbwaYZTjgsXq6cy8N38EecewgBbZYS1IYJraE/M
|
33
33
|
-----END CERTIFICATE-----
|
34
|
-
date: 2016-05-
|
34
|
+
date: 2016-05-13 00:00:00.000000000 Z
|
35
35
|
dependencies:
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: rspec
|
@@ -99,6 +99,8 @@ files:
|
|
99
99
|
- lib/rspeckled/plugins/authentication.rb
|
100
100
|
- lib/rspeckled/plugins/awesome_print.rb
|
101
101
|
- lib/rspeckled/plugins/bullet.rb
|
102
|
+
- lib/rspeckled/plugins/bundler.rb
|
103
|
+
- lib/rspeckled/plugins/capybara.rb
|
102
104
|
- lib/rspeckled/plugins/carrier_wave.rb
|
103
105
|
- lib/rspeckled/plugins/code_climate.rb
|
104
106
|
- lib/rspeckled/plugins/database_cleaner.rb
|
@@ -108,6 +110,7 @@ files:
|
|
108
110
|
- lib/rspeckled/plugins/factory_girl.rb
|
109
111
|
- lib/rspeckled/plugins/fakeredis.rb
|
110
112
|
- lib/rspeckled/plugins/features.rb
|
113
|
+
- lib/rspeckled/plugins/garbage_collection.rb
|
111
114
|
- lib/rspeckled/plugins/mocks.rb
|
112
115
|
- lib/rspeckled/plugins/omniauth.rb
|
113
116
|
- lib/rspeckled/plugins/rails/engine.rb
|
@@ -126,21 +129,10 @@ files:
|
|
126
129
|
- lib/rspeckled/plugins/wisper.rb
|
127
130
|
- lib/rspeckled/spec_helpers/active_record_basic.rb
|
128
131
|
- lib/rspeckled/spec_helpers/active_record_connection_setup.rb
|
132
|
+
- lib/rspeckled/spec_helpers/rails.rb
|
129
133
|
- lib/rspeckled/spec_helpers/rails_engine.rb
|
134
|
+
- lib/rspeckled/spec_helpers/rspeckled.rb
|
130
135
|
- lib/rspeckled/support.rb
|
131
|
-
- lib/rspeckled/support/expectations.rb
|
132
|
-
- lib/rspeckled/support/failures.rb
|
133
|
-
- lib/rspeckled/support/focused.rb
|
134
|
-
- lib/rspeckled/support/formatters.rb
|
135
|
-
- lib/rspeckled/support/garbage_collection.rb
|
136
|
-
- lib/rspeckled/support/heroku.rb
|
137
|
-
- lib/rspeckled/support/i18n.rb
|
138
|
-
- lib/rspeckled/support/mocks.rb
|
139
|
-
- lib/rspeckled/support/output.rb
|
140
|
-
- lib/rspeckled/support/pending.rb
|
141
|
-
- lib/rspeckled/support/rails.rb
|
142
|
-
- lib/rspeckled/support/random.rb
|
143
|
-
- lib/rspeckled/support/selenium.rb
|
144
136
|
- lib/rspeckled/vcr_matchers/uri_without_trailing_id.rb
|
145
137
|
- lib/rspeckled/version.rb
|
146
138
|
homepage:
|
metadata.gz.sig
CHANGED
@@ -1,3 +1,2 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
��}������F#O���d<4mA�B�ܧ:���y�&�a�h4���\ɝ��bֶEn˓�(��ly��g�|�5`C����!�.?Y<F�w�tA��)8��?{18-�]�Cr��%��n�sί$�d�1#
|
1
|
+
>�?\5�O��� �u�2*؈���Dܧ�Z���l��sA՝������e�%+({μ�J���@V]�:R�EO��N'�s��3Y%��:�@vA�r��ɯ��#���8�0���w���Y�Xc�#�����r-!bAB36_tz����A�E��3�vi&T#V��d�!
|
2
|
+
䍁,�[)��>�v@��
|
@@ -1 +0,0 @@
|
|
1
|
-
abort('DATABASE_URL environment variable is set') if ENV['DATABASE_URL']
|
@@ -1 +0,0 @@
|
|
1
|
-
require 'pp'
|
@@ -1,13 +0,0 @@
|
|
1
|
-
require 'rspeckled/plugins/rails/engine'
|
2
|
-
|
3
|
-
if defined? RSpec::Rails
|
4
|
-
RSpec.configure do |config|
|
5
|
-
config.infer_base_class_for_anonymous_controllers = true
|
6
|
-
|
7
|
-
config.infer_spec_type_from_file_location! if config.respond_to?(:infer_spec_type_from_file_location!)
|
8
|
-
|
9
|
-
if Pathname.pwd.join('spec', 'dummy', 'config', 'environment.rb').exist?
|
10
|
-
config.include Rspeckled::NamespacedEngineControllerRouteFix, :type => :controller
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
File without changes
|