質問編集履歴
1
丁寧な文書に加筆致しました。
test
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
bundle exec rspec spec/ テストがパスできません・・・
|
test
CHANGED
@@ -1,27 +1,33 @@
|
|
1
|
-
何度も失礼いたします。
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
いつも大変お世話になっております。
|
6
|
-
|
7
|
-
Ruby on Rails Tutorial
|
1
|
+
Ruby on Rails Tutorialに挑戦しているのですが、
|
2
|
+
|
8
|
-
|
3
|
+
見直して編集しなおしても下記のエラーによってテストがパスしません。
|
4
|
+
|
5
|
+
|
6
|
+
|
7
|
+
お手数ではございますが、お助けいただけないでしょうか。
|
8
|
+
|
9
|
-
|
9
|
+
どうぞ宜しくお願いいたします。
|
10
|
-
|
11
|
-
|
12
|
-
|
10
|
+
|
11
|
+
|
12
|
+
|
13
|
-
|
13
|
+
パソコン名:sample_app ユーザー名$ bundle exec rspec spec/
|
14
|
-
|
14
|
+
|
15
|
-
|
15
|
+
*FF*F............................
|
16
16
|
|
17
17
|
|
18
18
|
|
19
19
|
Pending:
|
20
20
|
|
21
|
-
|
21
|
+
UsersHelper add some examples to (or delete) /Users/yamadashunsuke/rails_projects/sample_app/spec/helpers/users_helper_spec.rb
|
22
22
|
|
23
23
|
# No reason given
|
24
24
|
|
25
|
+
# ./spec/helpers/users_helper_spec.rb:14
|
26
|
+
|
27
|
+
StaticPagesHelper add some examples to (or delete) /Users/yamadashunsuke/rails_projects/sample_app/spec/helpers/static_pages_helper_spec.rb
|
28
|
+
|
29
|
+
# No reason given
|
30
|
+
|
25
31
|
# ./spec/helpers/static_pages_helper_spec.rb:14
|
26
32
|
|
27
33
|
|
@@ -34,15 +40,23 @@
|
|
34
40
|
|
35
41
|
Failure/Error: it { should have_title(full_title('Sign up')) }
|
36
42
|
|
37
|
-
NoMethodError:
|
38
|
-
|
39
|
-
|
43
|
+
expected #has_title?("Ruby on Rails Tutorial Sample App | Sign up") to return true, got false
|
40
44
|
|
41
45
|
# ./spec/requests/user_pages_spec.rb:11:in `block (3 levels) in <top (required)>'
|
42
46
|
|
43
47
|
|
44
48
|
|
49
|
+
2) User pages signup page
|
50
|
+
|
51
|
+
Failure/Error: it { should have_content('Sign up') }
|
52
|
+
|
53
|
+
expected #has_content?("Sign up") to return true, got false
|
54
|
+
|
55
|
+
# ./spec/requests/user_pages_spec.rb:10:in `block (3 levels) in <top (required)>'
|
56
|
+
|
57
|
+
|
58
|
+
|
45
|
-
|
59
|
+
3) StaticPagesController GET '...' returns http success
|
46
60
|
|
47
61
|
Failure/Error: get '...'
|
48
62
|
|
@@ -50,13 +64,13 @@
|
|
50
64
|
|
51
65
|
No route matches {:action=>"...", :controller=>"static_pages"}
|
52
66
|
|
53
|
-
# ./spec/controllers/static_pages_controller_spec.rb:
|
67
|
+
# ./spec/controllers/static_pages_controller_spec.rb:7:in `block (3 levels) in <top (required)>'
|
54
|
-
|
55
|
-
|
56
|
-
|
68
|
+
|
69
|
+
|
70
|
+
|
57
|
-
Finished in 0.1
|
71
|
+
Finished in 0.51877 seconds
|
58
|
-
|
72
|
+
|
59
|
-
|
73
|
+
33 examples, 3 failures, 2 pending
|
60
74
|
|
61
75
|
|
62
76
|
|
@@ -66,13 +80,17 @@
|
|
66
80
|
|
67
81
|
rspec ./spec/requests/user_pages_spec.rb:11 # User pages signup page
|
68
82
|
|
83
|
+
rspec ./spec/requests/user_pages_spec.rb:10 # User pages signup page
|
84
|
+
|
69
|
-
rspec ./spec/controllers/static_pages_controller_spec.rb:
|
85
|
+
rspec ./spec/controllers/static_pages_controller_spec.rb:6 # StaticPagesController GET '...' returns http success
|
86
|
+
|
87
|
+
|
88
|
+
|
70
|
-
|
89
|
+
Randomized with seed 1912
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
90
|
+
|
91
|
+
|
92
|
+
|
75
|
-
|
93
|
+
**[ user_pages_spec.rbの中身 ]**
|
76
94
|
|
77
95
|
|
78
96
|
|
@@ -104,7 +122,9 @@
|
|
104
122
|
|
105
123
|
|
106
124
|
|
107
|
-
|
125
|
+
**[ static_pages_controller_spec.rbの中身 ]**
|
126
|
+
|
127
|
+
|
108
128
|
|
109
129
|
require 'spec_helper'
|
110
130
|
|
@@ -132,7 +152,9 @@
|
|
132
152
|
|
133
153
|
|
134
154
|
|
135
|
-
|
155
|
+
**[ users_helper_specの中身 ]**
|
156
|
+
|
157
|
+
|
136
158
|
|
137
159
|
require 'spec_helper'
|
138
160
|
|
@@ -140,6 +162,42 @@
|
|
140
162
|
|
141
163
|
# Specs in this file have access to a helper object that includes
|
142
164
|
|
165
|
+
# the UsersHelper. For example:
|
166
|
+
|
167
|
+
#
|
168
|
+
|
169
|
+
# describe UsersHelper do
|
170
|
+
|
171
|
+
# describe "string concat" do
|
172
|
+
|
173
|
+
# it "concats two strings with spaces" do
|
174
|
+
|
175
|
+
# helper.concat_strings("this","that").should == "this that"
|
176
|
+
|
177
|
+
# end
|
178
|
+
|
179
|
+
# end
|
180
|
+
|
181
|
+
# end
|
182
|
+
|
183
|
+
describe UsersHelper do
|
184
|
+
|
185
|
+
pending "add some examples to (or delete) #{__FILE__}"
|
186
|
+
|
187
|
+
end
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
**[ static_pages_helper_spec.rbの中身 ]**
|
192
|
+
|
193
|
+
|
194
|
+
|
195
|
+
require 'spec_helper'
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
# Specs in this file have access to a helper object that includes
|
200
|
+
|
143
201
|
# the StaticPagesHelper. For example:
|
144
202
|
|
145
203
|
#
|
@@ -163,3 +221,17 @@
|
|
163
221
|
pending "add some examples to (or delete) #{__FILE__}"
|
164
222
|
|
165
223
|
end
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
申し訳ありませんが、お手上げな状態で><
|
228
|
+
|
229
|
+
どうかご教示のほど、よろしくお願いいたします。
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
また、いまいちspecの説明が自分の中で腑に落ちていないので
|
234
|
+
|
235
|
+
併せてご教示いただければ幸いです。
|
236
|
+
|
237
|
+
どうぞ宜しく御願い致します・
|