Skip to content

Latest commit

 

History

History
66 lines (59 loc) · 1.26 KB

directory_structure.md

File metadata and controls

66 lines (59 loc) · 1.26 KB

Project directory structure

Example directory structure and options

Separate a separate directory for each utility and test it with test_spec.sh. The execution directory for testing is where the specfile is located.

<PROJECT-ROOT>
├─ .shellspec
│
├─ script1/
│   ├─ script1.sh
│   └─ test_spec.sh
│
├─ script2/
│   ├─ script2.sh
│   └─ test_spec.sh
│
├─ spec/
│   ├─ spec_helper.sh
│   │        :
# .shellspec
--default-path "**/test_spec.sh"
--execdir @specfile

Separate a separate directory for each utility and test it with spec/*_spec.sh. The test execution directory is where the script is located.

<PROJECT-ROOT>
├─ .shellspec
│
├─ script1/
│   ├─ .shellspec-basedir
│   ├─ bin/
│   │   ├─ script1.sh
│   │   │    :
│   └─ spec/
│        ├─ script1_spec.sh
│        │    :
│
├─ script2/
│   ├─ .shellspec-basedir
│   ├─ bin/
│   │   ├─ script2.sh
│   │   │    :
│   └─ spec/
│        ├─ script2_spec.sh
│        │    :
│
├─ spec/
│   ├─ spec_helper.sh
│   ├─ support/
│   │        :
# .shellspec
--default-path "**/spec"
--execdir @basedir/bin`