coffeelint-no-chai-getters
Coffeelint rule that detects code using a chai getter without function invocation
Last updated 4 years ago by robertsami .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install coffeelint-no-chai-getters 
SYNC missed versions from official npm registry.

coffeelint-no-chai-getters

Coffeelint rule that detects code using a chai getter without function invocation. This is useful for codebases moving off the chai matcher getter syntax, and using dirty-chai.

Eg:

expect(someDopeSpy).ok

This is dangerous, as if it's spelled incorrectly it will fail silently. This is why we prefer the function invocation syntax provided by dirty-chai https://www.npmjs.com/package/dirty-chai

The only problem with dirty-chai is that now the getter syntax will fail silently. So, this linter aims to warn against the use of the old getter syntax.

Installation

Add the following to your package.json file:

"devDependencies" : {
	...
	"coffeelint-no-chai-getters": "git://github.com/benchling/coffeelint-no-chai-getters.git#master",
	...
}

Usage

Add the following configuration to coffeelint.json:

"no_chai_getters": {
    "module": "coffeelint-no-chai-getters",
    "level": "error",
},

Configuration

There are currently no configuration options.

Current Tags

  • 0.0.8                                ...           latest (4 years ago)

8 Versions

  • 0.0.8                                ...           4 years ago
  • 0.0.7                                ...           4 years ago
  • 0.0.6                                ...           4 years ago
  • 0.0.5                                ...           4 years ago
  • 0.0.4                                ...           4 years ago
  • 0.0.3                                ...           4 years ago
  • 0.0.2                                ...           4 years ago
  • 0.0.1                                ...           4 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 1
Last Month 10
Dependencies (2)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |