forked from calatrava/calatrava
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproject.feature
48 lines (44 loc) · 1.65 KB
/
project.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
Feature: Projects
In order to save money but still create the most awesome mobile app
As a cross-platform mobile developer
I want to use Calatrava to create a project
Scenario: Create a project using the standard Calatrava template
When I run `calatrava create simple`
Then the exit status should be 0
And the following directories should exist:
| simple |
| simple/config |
| simple/droid |
| simple/features |
| simple/ios |
| simple/kernel |
| simple/shell |
| simple/web |
And the file "simple/calatrava.yml" should contain "project_name: simple"
Scenario: Templates can have deeply nested directories and files
Given the following directories exist:
| nested |
| nested/dir |
| nested/dir/sub |
And the following files exist:
| nested/sample |
| nested/.config |
| nested/dir/sub/sample2 |
When I run `calatrava create proj --template nested`
Then the following directories should exist:
| proj |
| proj/dir |
| proj/dir/sub |
And the following files should exist:
| proj/sample |
| proj/.config |
| proj/dir/sub/sample2 |
Scenario: Template files can themselves be templates
Given a directory named "template"
And a file named "template/.tmpl.calatrava" with:
"""
Sample {{ project_name }}
"""
When I run `calatrava create templatized --template template`
Then a file named "templatized/.tmpl" should exist
And the file "templatized/.tmpl" should contain "Sample templatized"