Announce: Jasmine for GJS
- From: Philip Chimento <philip chimento gmail com>
- To: javascript-list gnome org
- Subject: Announce: Jasmine for GJS
- Date: Thu, 5 Mar 2015 22:56:43 -0800
Hi,
I've been working on a port of the Jasmine [1] test environment to GJS and I have just cut a first release [2]. Feel free to try it out and I'd be happy to hear any feedback.
For a quick introduction to Jasmine, it's a test runner for JS that understands behavior-driven test suites like the following:
const MyModule = imports.myModule;
describe('My object', function () {
let myObject;
beforeEach(function () {
myObject = new MyModule.MyObject();
});
it('constructs correctly', function () {
expect(myObject).toBeDefined();
});
it('quotes Vogon poetry', function () {
expect(myObject.getPoetry()).toMatch('Oh freddled gruntbuggly');
});
});
This port of Jasime can produce reports in several different formats, both human-readable and machine-readable. In particular, it can do TAP output so that you can integrate it nicely with Autotools.
For more examples, see Jasmine GJS's own test suite [3].
For more info, see the upstream Jasmine documentation [4].
[Date Prev][
Date Next] [Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]