
Security News
The Nightmare Before Deployment
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.
spectacular
Advanced tools
Spectacular is a BDD framework for CoffeeScript and JavaScript whose attempt to bring the power of RSpec to JavaScript. Spectacular try to favor the best practices used for writing better RSpec tests in its design.
This is the kind of tests you can write with Spectacular:
describe Array, ->
given 'item', -> foo: 'bar'
it -> should exist
itsInstance 'length', -> should equal 0
describe '::indexOf', ->
context 'with an item not present in the array', ->
itsReturn with: (-> [@item]), -> should equal -1
context 'with an item present in the array', ->
subject 'array', -> [@item]
specify 'the returned value', ->
expect(@array.indexOf @item).to equal 0
For more information view the documentation
Spectacular is available as a npm module, you can then install it with:
npm install -g spectacular
This will install Spectacular globally and allow you to use the Spectacular command line tool.
The most simple way to use the spectacular command line tool is as follow:
spectacular test specs/**/*.spec.js
| `test` | Runs the tests on NodeJS. |
| `server` | Starts a server. The specs can then be accessed from a browser at the the following address: `http://localhost:5000`. The default port can be changed by setting the `PORT` environment variable. |
| `phantomjs` | Assuming you have PhantomJS installed, it will starts a server and run the test on PhantomJS. |
| `slimerjs` | Assuming you have SlimerJS installed, it will starts a server and run the test on SlimerJS. |
| `-c, --coffee` | Add support for CoffeeScript files. You can now run your specs with: `spectacular --coffee specs/**/*.coffee`. |
| `-f, --format` | Select the console output format (progress|documentation). |
| `-r, --require PATH` | Adds `PATH` to the array of paths to includes. |
| `-v, --verbose` | Enable verbose output. |
| `-t, --trace` | Enable stack trace report for failures (default is `true`). |
| `--long-trace` | By default the stack traces are cropped after 6 lines to limit the amount of output. You can display the full stack trace with this option. |
| `-p, --profile` | Add a report with the 10 slowest examples at the end of the output. |
| `-d, --documentation` | deprecated Use the format option instead |
| `-s, --server` | deprecated Use the `server` command instead. |
| `--phantomjs` | deprecated Use the `phantomjs` command instead. |
| `--phantomjs-bin PATH` | Pass the path to the PhantomJS binary. |
| `--slimerjs-bin PATH` | Pass the path to the SlimerJS binary. |
| `--source GLOB` | |
| `--map, --source-map` | Enable the support for CoffeeScript source map on both node and browsers. When using this mode with the browser without relying on the Spectacular server additional setup is required, please see the [Source Map Support](http://abe33.github.com/spectacular/#Source-Map-Support) section of the documentation for details. |
| `-m, --matchers PATH` | deprecated Use `--require PATH` instead. |
| `--helpers PATH` | deprecated Use `--require PATH` instead. |
| `--fixtures PATH` | Specify the path where project fixtures can be found, by default fixtures are loaded from `./specs/support/fixtures`. |
| `--no-trace` | Remove stack trace from failures reports. |
| `--random` | Enable tests randomization. |
| `--no-random` | Disable tests randomization. |
| `--seed INT` | Sets the seed for the tests randomization. |
| `--colors` | Enable coloring of the output. |
| `--no-colors` | Disable coloring of the output. |
| `--no-matchers` | deprecated Don't require you matchers instead. |
| `--no-helpers` | deprecated Don't require your helpers instead. |
Options can also be defined in a .spectacular file at the root of your project.
I decided to start using the AngularJS commit messages convention for this project. Please use the same convention as well for commits in PR.
I also try to follow Nvie's Successful Git Branching Model. Meaning that I do the daily work in
the develop branch and try to keep the master branch with only the released
versions. All the pull request should be done to the develop branch.
FAQs
Advanced BDD framework for CoffeeScript and JavaScript
We found that spectacular demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.

Research
/Security News
Impostor NuGet package Tracer.Fody.NLog typosquats Tracer.Fody and its author, using homoglyph tricks, and exfiltrates Stratis wallet JSON/passwords to a Russian IP address.

Security News
Deno 2.6 introduces deno audit with a new --socket flag that plugs directly into Socket to bring supply chain security checks into the Deno CLI.