Skip to content
| Marketplace
Sign in
Visual Studio Code>Testing>Shellspec TesterNew to Visual Studio Code? Get it now.
Shellspec Tester

Shellspec Tester

Preview

Stefan Mayrhofer

|
620 installs
| (0) | Free
| Sponsor
Integrates shellspec testing into VSCode
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

shellspec-tester

This extension helps running shellspec tests and shows tests and results in the "Testing" tab.

Features

  • See your specified tests in "Testing" tab
  • Quickly go to each test
  • Run tests
  • Get test results
  • Quickly create tests from snippets
  • Initialise shellspec from command (Shellspec: Run shellspec init)

Shellspec_Init

Snippets

This extension also contains snippets for many commonly used shellspec commands like:

  • Creating a group
  • Creating a test
  • Add text block
  • Expect (variable, path, output)

These can be invoked by typing "shellspec:" - vscode should then suggest the available templates.

Shellspec_Snippets

Get native test view

If you have opened your workspace in a folder which has shellspec-tests, they will be automatically imported into VSCodes "Testing" tab.

The test detection uses the following command to detect specfiles:

bash shellspec --list specfiles

Found tests are then parsed (within VSCode extension) and categorised in the following structure:

  • fileA_spec.sh
    • GroupA
      • SubgroupA
        • TestA
        • TestB
      • SubgroupB
    • GroupB
      • TestC
  • fileB_spec.sh
    • GroupD
    • TestD

You can right click on any test or group to go to its specification in the specfile where it is defined.

Shellspec_Run_Tests

Requirements

You need to have shellspec installed.

Settings

  • shellspec.enable: Enable extension
  • shellspec.executablePath: Path to shellspec executable or executable name (if in path)

Known Issues

My code is probably very inefficient, but I am not a javascript/typescript person and new to VSCode.

Disclaimer

This is my first VSCode extension, and I am not a typescript programmer. Everything is provided as-is. I do not guarantee anything, but I try my best to create a helpful extension.

Do you think you can do better? I would be happy to receive a Merge Request for fixes, new features, code cleanup...

Release Notes

0.0.4

  • Correctly display skipped tests

0.0.3

  • Run shellspec --syntax-check after every save and when loading plugin.
  • Show information about syntax errors in specfiles found by shellspec in editor

0.0.2

Fix bug detecting Test IDs containing " and '

0.0.1

Initial release

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft