Skip to content

Releases: japa/core

Allow context to be configurable at suite level and remove assert module

10 Jan 06:46
Compare
Choose a tag to compare
  • refactor: make context configurable at suite level as well 0a1210c
  • refactor: remove assert in favor of dedicated assert package 304d1f7

Use the https://github.com/japa/assert package for assertions

v5.0.1-0...v5.0.2-0

Make test context configurable and decoupling assert from context

10 Jan 05:48
Compare
Choose a tag to compare
  • refactor: allow custom context for tests 56062cb

v5.0.0-0...v5.0.1-0

Stepping stone for v5

07 Jan 10:13
Compare
Choose a tag to compare

Japa is getting a rewrite with a new core, a standalone test runner and proper docs website. Please wait for the final release for the documentation.

The new package is published under @japa/core

Support ES modules and drop Node 10/12 support

28 Oct 18:11
Compare
Choose a tag to compare

Remove support for Node versions before 14.17.0 and add support for ES modules. You can enable ESM support as follows.

import japa from 'japa'

japa.configure({
  files: ['test/**/*.spec.js'],
  experimentalEsmSupport: true
})
  • chore: update np d7dccef
  • docs(README): document experimentalEsmSupport flag 33ea661
  • chore: move husky hooks to .husky dir 6a6a672
  • ci: use github actions 7c78b7a
  • feat: add support for importing esm files 5052742
  • style: fix linting errors bb9e2ca
  • chore(deps): bump trim-newlines from 3.0.0 to 3.0.1 (#37) 709b85b
  • chore(deps): bump glob-parent from 5.1.1 to 5.1.2 (#36) 3d57d20
  • chore(deps): bump hosted-git-info from 2.8.8 to 2.8.9 (#35) f64cd4f
  • chore(deps): bump minimist from 1.2.0 to 1.2.5 (#18) 928137c
  • chore(deps): bump handlebars from 4.7.6 to 4.7.7 (#34) 72d2395
  • improvement: add coverage section (#32) 70bc520
  • chore(deps): bump dot-prop from 4.2.0 to 4.2.1 (#28) c43ac52
  • chore(deps): bump ini from 1.3.5 to 1.3.7 (#27) 79d787c
  • refactor: use String.prototype.padEnd instead of right-pad (#20) b2bb8fe

New Contributors

Full Changelog: v3.1.1...v4.0.0

Using jest diff over variable diff

05 Jun 06:36
Compare
Choose a tag to compare
  • improvement: use jest-diff over variable-diff ce6e80b

v3.1.0...v3.1.1

Adding support for test.only

30 May 19:40
Compare
Choose a tag to compare
  • chore: add todo file 87d4f24
  • improvement: add first class support inside group for test.only d5bb6a9
  • improvement: group does not execute hooks when no tests are defined 014c9bb
  • chore: update meta files afb0d63
  • chore: remove ow 78fc276
  • feat: add test.only method to run a single test 311a092
  • chore: update dependencies 5522ad6

v3.0.1...v3.1.0

Fixing skip in CI

04 Sep 08:49
Compare
Choose a tag to compare
  • chore(package): update dependencies d83c47c

v3.0.0...v3.0.1

Dropping support for Node 8&9

28 Aug 09:37
Compare
Choose a tag to compare

Moving forward, Japa support Node.js 10.15.3 and above. It was required to keep the dependencies up to date and free from vulnerabilities.

  • chore: remove typedoc single line plugin 17c5dfb
  • chore: remove nyc a332007
  • chore: add np for releases 9a39531
  • ci: remove travis in favor of circle 3484f3a
  • chore(package): update dependencies 598d7d3

2.0.10...v3.0.0

Big bang re-write 🎉

22 Sep 14:54
Compare
Choose a tag to compare

Japa 2.0 is out with a Big Bang re-write. The end-user API is more or less same. However, the core has been moved to Typescript and is smaller, and faster than earlier.

Big wins

  • Moved to Typescript. Which means, now you can enjoy autocomplete when writing tests.

    japa-autocomplete

  • The core is simpler, leaner and marginally faster than the older versions.

  • In-built support to run multiple test files, without any CLI.

Improvements

  • The flow of tests and hooks is more streamlined and explained here.

  • Now tests relying on done callback, can also use the await keyword.

    test('process one job at a time', async (assert, done) => {
      queue.on('job', (data) => {
        assert.deepEqual(data, {})
        done()
      })
    
      await queue.run()
    })
  • Better support for grep. Earlier it has to be a substring of the test title. Now you can define RegExp too.

    const { configure } = require('japa')
    
    configure({
      grep: 'users'
    })
    
    // or regex like string
    configure({
      grep: 'user(s)?'
    })
    
    // even regex
    configure({
      grep: /user(s)?/
    })

Breaking changes

  • The need of japa-cli has been removed. We recommend using a master test file and configure the tests using the configure method.
  • Calling test.timeout at a global level doesn't work anymore and again the configure method can be used to define the global timeout for all the tests.
  • The module japa/cli has been removed. This was used by the CLI to interact with the Japa core and hence is not required.
  • The structure of japa/api has been changed too.

First Version

19 Jan 21:11
Compare
Choose a tag to compare

The first version with all the goodness