File tree Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Original file line number Diff line number Diff line change
1
+ require_relative '../../support/utils'
2
+ include Utils
3
+
4
+ describe 'Footer Component' , type : :feature , js : true do
5
+
6
+ it 'Example 1' do
7
+
8
+ class ExamplePage < Page ::Cell ::Page
9
+
10
+ def response
11
+ components {
12
+ # simple footer tag
13
+ footer do
14
+ plain 'hello world!'
15
+ end
16
+
17
+ # advanced footer tag
18
+ footer id : 'my-unique-footer' , class : 'awesome-footer' do
19
+ pg class : 'footer-text' , text : 'hello world!'
20
+ end
21
+ }
22
+ end
23
+
24
+ end
25
+
26
+ visit "/example"
27
+
28
+ static_output = page . html
29
+
30
+ expected_static_output = <<~HTML
31
+ < footer > hello world!</ footer >
32
+ < footer id ="my-unique-footer " class ="awesome-footer ">
33
+ < p class ="footer-text "> hello world!</ p >
34
+ </ footer >
35
+ HTML
36
+
37
+ expect ( stripped ( static_output ) ) . to include ( stripped ( expected_static_output ) )
38
+ end
39
+
40
+ end
You can’t perform that action at this time.
0 commit comments