Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/bash-bastion/shelltest

A test runner for POSIX-compliant shells
https://github.com/bash-bastion/shelltest

ash basalt bash dash ksh pdksh sh shell tdd testing zsh

Last synced: about 2 months ago
JSON representation

A test runner for POSIX-compliant shells

Awesome Lists containing this project

README

        

# shelltest

A test runner for POSIX shells

## Features

- POSIX compliant
- No eval
- Uses only builtins
- Perform tests with `[`, etc.
- TAPS output
- `setup`, `setup_file`, `teardown`, `teardown_file`
- Utility functions `t_is_function`, `t_get_shell_version`, `t_assert`

## Tested on

- [ ] sh
- [ ] BusyBox sh
- [ ] ash
- [ ] dash (Debian variant of NetBSD ash)
- [ ] yash
- [ ] oil
- [ ] nsh
- [ ] bash
- [ ] zsh
- [ ] ksh (2020.0.0)
- [ ] pdksh
- [ ] mksh (MirBSD fork of OpenBSD pdksh)
- [ ] loksh (Linux port of OpenBSD pdksh)
- [ ] oksh (General port of OpenBSD pdksh)

More rigorous test suite coming soon...

## Installation

Use [Basalt](https://github.com/hyperupcall/basalt), a Bash package manager, to install this project globally

```sh
basalt global add hyperupcall/shelltest
```

## Usage

```sh
shelltest ./tests
```