File tree Expand file tree Collapse file tree 3 files changed +15
-4
lines changed
lib/hyper-operation/transport Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Original file line number Diff line number Diff line change 23
23
specs:
24
24
hyper-spec (1.0.0.lap28 )
25
25
capybara
26
- chromedriver-helper
26
+ chromedriver-helper ( = 1.2.0 )
27
27
libv8 (~> 6.3.0 )
28
28
method_source
29
29
mini_racer (~> 0.1.15 )
122
122
babel-source (>= 4.0 , < 6 )
123
123
execjs (~> 2.0 )
124
124
builder (3.2.3 )
125
- capybara (3.7.2 )
125
+ capybara (3.8.0 )
126
126
addressable
127
127
mini_mime (>= 0.1.3 )
128
128
nokogiri (~> 1.8 )
@@ -350,6 +350,7 @@ PLATFORMS
350
350
351
351
DEPENDENCIES
352
352
bundler
353
+ chromedriver-helper
353
354
database_cleaner
354
355
hyper-component !
355
356
hyper-operation !
Original file line number Diff line number Diff line change @@ -3,6 +3,16 @@ module Hyperloop
3
3
class InternalClassPolicy
4
4
5
5
def initialize ( regulated_klass )
6
+ unless regulated_klass . is_a? ( Class )
7
+ # attempt to constantize the class in case eager_loading in production
8
+ # has loaded the policy before the class. THis will insure that if
9
+ # there is a class being regulated, it is loaded first.
10
+ begin
11
+ regulated_klass . constantize
12
+ rescue NameError
13
+ nil
14
+ end
15
+ end
6
16
@regulated_klass = regulated_klass
7
17
end
8
18
Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ def connect(*args)
145
145
Hyperloop . connect_session = true
146
146
mount "TestComponent"
147
147
evaluate_ruby "Hyperloop.go_ahead_and_connect"
148
- wait_for_ajax
148
+ wait_for_ajax rescue nil
149
149
evaluate_ruby "MyControllerOp.run(data: 'hello')"
150
150
page . should have_content ( "hello" )
151
151
end
@@ -285,7 +285,7 @@ def connect(*args)
285
285
mount "TestComponent"
286
286
sleep 0.25
287
287
evaluate_ruby "Hyperloop.go_ahead_and_connect"
288
- wait_for_ajax
288
+ wait_for_ajax rescue nil
289
289
evaluate_ruby "MyControllerOp.run(data: 'hello')"
290
290
page . should have_content ( "hello" )
291
291
end
You can’t perform that action at this time.
0 commit comments