Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
]).then(results => {
const [statusRes, res] = results;
const stardogVersion = statusRes.body['dbms.version'].value;
expect(res.status).toBe(200);
expect(res.body).toHaveProperty('data');
expect(res.body.data).toEqual({
sparql:
'SELECT *\nFROM \n{\n?0 rdf:type :Character .\n?0 :name ?1 .\n}\n',
fields: { '0': { '1': 'name' } },
// > 6.1.3 captures snapshot versions of 6.1.4
plan: semver.gt(stardogVersion, '6.1.3')
? {
dataset: { from: 'all' },
plan: jsonPlan,
prefixes: { '': 'http://api.stardog.com/' },
}
: textPlan,
});
}));