• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mochajs / mocha / 6790 / 7
93%
main: 94%

Build:
Build:
LAST BUILD BRANCH: v11.x
DEFAULT BRANCH: main
Ran 10 Jan 2020 02:44PM UTC
Files 48
Run time 3s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

10 Jan 2020 02:34PM UTC coverage: 92.889% (+0.08%) from 92.814%
6790.7

Pull #4133

travis-ci

web-flow
Throw a descriptive error when a non-function is given to a runnable

Given a test such as:

```js
it('foobars', 4);
```

mocha used to throw the following error: `fn.call is not a function`.

While technically true, I have personally spent some minutes of my life chasing
what looked like a bug in the test itself, and not in the call to `it`. A more
descriptive error message helps bring attention to where the problem originates.

(Thanks to [ssube](https://github.com/ssube) for helping with the error wording.)
Pull Request #4133: Throw a descriptive error when a non-function is given to a runnable

1018 of 1179 branches covered (86.34%)

2743 of 2953 relevant lines covered (92.89%)

691.33 hits per line

Source Files on job 6790.7
  • Tree
  • List 0
  • Changed 11
  • Source Changed 1
  • Coverage Changed 11
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 6134
  • Travis Job 6790.7
  • cedbab1d on github
  • Prev Job for on handle-non-function-runnable (#6789.7)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc