shellspec
shellspec/shellspec · Public GitHub repository
A full-featured BDD unit testing framework for bash, ksh, zsh, dash and all POSIX shells
Open the project to try its demo, view the repository, or save it to your collection. Repository and demo actions use RepoShelf’s sign-in flow.

About this project
Author-written excerpt from the project README.
ShellSpec is a full-featured BDD unit testing framework for dash, bash, ksh, zsh and all POSIX shells that provides first-class features such as code coverage, mocking, parameterized test, parallel execution and more. It was developed as a dev/test tool for cross-platform shell scripts and shell script libraries. ShellSpec is a new modern testing framework released in 2019, but it's already stable enough. With lots of practical CLI features and simple yet powerful syntax, it provides you with a fun shell script test environment.
&style=flat-square) &style=flat-square) &style=flat-square) &style=flat-square)
Thank you for your interest in ShellSpec. Please visit 🚩the official website to know the impressive features!
- It will be executed in the shell specified by the shebang not the shell running the specfile.
- The coverage of the shell script will not be measured.
- Cannot refer to variables inside the shell script.
- Shell built-in commands cannot be mocked.
- Functions defined inside the shell script cannot be mocked.
Requirements and intended audience
ShellSpec is a full-featured BDD unit testing framework for dash, bash, ksh, zsh and all POSIX shells that provides first-class features such as code coverage, mocking, parameterized test, parallel execution and more. It was developed as a dev/test tool for cross-platform shell scripts and shell script libraries. ShellSpec is a new modern testing framework released in 2019, but it's already stable enough. With lots of practical CLI features and simple yet powerful syntax, it provides you with a fun shell script test environment.
- Account · Required
The environment variable SHELL is the user login shell, not the currently running shell.
Not recorded: external api key, paid service, self-hosting. Missing information does not mean there are no requirements.
Statements extracted from the author’s documentation · Checked 2026-11-01. Source: https://github.com/shellspec/shellspec/blob/master/README.md
Recorded maintenance information
Last recorded source update: 2025-11-24. Saved release: 0.28.1 · 2021-01-11. These dates do not guarantee ongoing maintenance.
- Technologies
- Shell
- Licence
- MIT. Generally permits modification and commercial use, subject to the licence’s notices and conditions.
- Demo check
- A public page loaded on 2026-11-20. This does not test every feature.
Browse related categories
More projects to explore
awesome-selfhosted
awesome-selfhosted/awesome-selfhosted
A list of Free Software network services and web applications which can be hosted on your own servers
awesome-go
avelino/awesome-go
A curated list of awesome Go frameworks, libraries and software
NextChat
ChatGPTNextWeb/NextChat
✨ Zero-config AI chat assistant. No API key needed — sign up and instantly chat with GPT-5, Claude 4, Gemini 2.5, DeepSeek & 100+ top models. Pay-as-you-go saves you more. Available on Web, iOS, macOS, Android, Linux, Windows.
vue-element-admin
PanJiaChen/vue-element-admin
A magical vue admin https://panjiachen.github.io/vue-element-admin