Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fox

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fox

Pragmatic Testing Framework For NodeJS and Browsers.

  • 1.6.2
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Fox Build Status

A new pragmatic JavaScript testing framework for both NodeJS and browsers. Screencast

Features

  • No configuration needed.
  • NodeJS and browsers supported. All you need is to pass -b parameter. It compiles your source code for browsers automatically with OneJS
  • Keep the browsers open, your tests will be run on any code change automatically.
  • Headless testing with PhantomJS with -bv parameter.
  • Beautified error output that show failing lines.
  • ChaiJS is injected to every module to avoid repeating.
  • Mostly compatible with Mocha.

Install

$ npm install -g fox

First Steps

Create a new test document and name it test.js. ChaiJS' expect and assert modules are injected to the test modules by default;

describe('Number', function(){
  it('converts a date to a number', function(){    
      expect( Number(new Date) ).to.be.a('number')
  })
})

Available BDD methods:

  • before
  • beforeEach
  • describe
  • it
  • afterEach
  • after

Running on Node

$ fox # It'll look modules like test.js and test/index by default. You can specify them manually; fox test_foo.js test_b*.js
OK, passed 1 test.

Running On Browsers

$ fox -b
Visit localhost:7559 to run tests on a web browser

Once you pass -b parameter, fox compiles your source code for browsers and publishes a web page where you can run and see the test results.

Running On PhantomJS Headlessly

If you have PhantomJS installed in your system, run fox with -bv parameters to run the tests headlessly;

$ fox -bv

FAQs

Package last updated on 24 Oct 2013

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc