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

graphql / graphql-js / 867 / 1
99%
master: 98%

Build:
Build:
LAST BUILD BRANCH: directives
DEFAULT BRANCH: master
Ran 25 Mar 2016 12:24AM UTC
Files 131
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

25 Mar 2016 12:20AM UTC coverage: 99.421% (+0.04%) from 99.385%
867.1

push

travis-ci

leebyron
[RFC] Add explicit context arg to graphql execution

This *BREAKING* change introduces a new argument to the GraphQL execution API which is presented to resolution functions: `context`.

This solves a long-standing point of confusion about the correct way to represent authentication or a "viewer context" in which a query is executed.

Previously, we suggested that the `rootValue` contain any authentication tokens, however this led to awkward code:

```
resolve: (val, args, { rootValue: { authToken } }) { ... }
```

Which can now be written as:

```
resolve: (val, args, authToken) { ... }
```

The `info` object is still created and provided to resolution functions, and the `rootValue` is still provided within it, however it is now the *fourth* argument rather than the *third*.

6186 of 6222 relevant lines covered (99.42%)

1317.15 hits per line

Source Files on job 867.1
  • Tree
  • List 0
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 867
  • Travis Job 867.1
  • d7cc6f9a on github
  • Prev Job for on context (#830.1)
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