forked from ruhoh/ruhoh.rb
/
stylesheets.feature
53 lines (51 loc) · 1.68 KB
/
stylesheets.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
Feature: Stylesheets
As a content publisher
I want to load stylesheets
so I can make my content presentation pleasing to the eye and intuitive for my readers
Scenario: Defining stylesheets
Given a config file with value:
"""
{
"production_url" : "http://www.fakedomain.com"
}
"""
And some files with values:
| file | body |
| stylesheets/base.css | body { color: black } |
| stylesheets/app.css | div { color: black } |
| stylesheets/custom.css | div { color: black } |
And the file "_root/index.html" with body:
"""
{{# stylesheets.load }}
base.css
app.css
custom.css
{{/ stylesheets.load }}",
"""
When I compile my site
Then my compiled site should have the file "index.html"
And this file should have the fingerprinted stylesheets "base, app, custom"
Scenario: Defining stylesheets in a theme
Given a config file with value:
"""
{
"production_url" : "http://www.fakedomain.com",
"sample_theme": { "use" : "theme" }
}
"""
And some files with values:
| file | body |
| stylesheets/base.css | blah {} |
| sample_theme/stylesheets/app.css | blah {} |
| sample_theme/stylesheets/custom.css | blah {} |
And the file "_root/index.html" with body:
"""
{{# stylesheets.load }}
base.css
app.css
custom.css
{{/ stylesheets.load }}",
"""
When I compile my site
Then my compiled site should have the file "index.html"
And this file should have the fingerprinted stylesheets "base, app, custom"