# run-jasmine

> run-jasmine

Latest version **1.0.0** (published 2017-12-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install run-jasmine
pnpm add run-jasmine
yarn add run-jasmine
bun add run-jasmine
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2017-12-23 |
| First published | 2017-12-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Andres Suarez |
| Maintainers | zertosh |
| Keywords | jasmine |

## Links

- npm: https://www.npmjs.com/package/run-jasmine
- Repository: https://github.com/zertosh/run-jasmine
- Homepage: https://github.com/zertosh/run-jasmine#readme
- Issues: https://github.com/zertosh/run-jasmine/issues
- npm.io page: https://npm.io/package/run-jasmine

## Recent versions

- 1.0.0 (latest) — 2017-12-23

## README

# run-jasmine [![Build Status](https://travis-ci.org/zertosh/run-jasmine.svg?branch=master)](https://travis-ci.org/zertosh/run-jasmine)

Prepares and executes jasmine in the current environment, only if jasmine is not defined. This is useful for having self-executing test files.

When your IDE is configured to execute `.js` files through `node` (like with a [Sublime build system](https://stackoverflow.com/questions/14427520/node-js-build-system-in-sublime-text-2)), this allows you quickly run a test without having to configure anything.

## Usage

1. Add this module and `jasmine` as dependencies:

  ```sh
  $ npm install --save-dev jasmine run-jasmine
  ```

2. Then, in your test files, add:

  ```js
  require('run-jasmine')();
  ```

## Example

Say you have `test/verify-test.js`, and it looks like this:

```js
require('run-jasmine')();

describe('verify-test', () => {
  it('works', () => {
    expect(true).toBe(true);
  });
});
```

By calling `run-jasmine` before the specs are defined, you can run this test in two ways:

  1. Through jasmine, with `./node_modules/.bin/jasmine test/verify-test.js`.
  2. Or, by running the script directly, with `node test/verify-test.js`.

---
_Source: https://npm.io/package/run-jasmine · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
