@bigtest/client
Advanced tools
Comparing version 0.1.0-60e6d1c3 to 0.1.0-83153e3f
{ | ||
"name": "@bigtest/client", | ||
"version": "0.1.0-60e6d1c3", | ||
"version": "0.1.0-83153e3f", | ||
"description": "Communicate with a BigTest Orchestrator", | ||
@@ -23,3 +23,3 @@ "main": "dist/cjs/index.js", | ||
"@bigtest/effection": "^0.5.1", | ||
"@effection/events": "^0.7.6", | ||
"@effection/events": "^0.7.7", | ||
"effection": "^0.7.0", | ||
@@ -26,0 +26,0 @@ "websocket": "^1.0.31" |
@@ -1,3 +0,27 @@ | ||
# @bigtest/globals | ||
# @bigtest/client | ||
Interact with a remote bigtest server with effection-native operations | ||
## Synopsis | ||
The client class allows you to evaluate GraphQL queries, mutations, | ||
and subscriptions against a remote bigtest orchestrator. It also has | ||
the capacity to run "live" queries which return new results for the | ||
query every time that the internal state changes. | ||
``` javascript | ||
import { Client } from `@bigtest/client`; | ||
export function* countAgentsAt(url) { | ||
// create the client. After this operation completes, the client | ||
// will be connected to the orchestrator over websockets. | ||
let client = yield Client.create(url); | ||
let result = yield client.query(`{ agents { agentId } }`); | ||
return result.agents.length; | ||
} | ||
``` | ||
To run the tests: | ||
@@ -4,0 +28,0 @@ |
21928
32
Updated@effection/events@^0.7.7