diff --git a/gremlin-javascript/src/main/javascript/gremlin-javascript/test/cucumber/feature-steps.js b/gremlin-javascript/src/main/javascript/gremlin-javascript/test/cucumber/feature-steps.js index 38d0d084c75..3e6ed1e5254 100644 --- a/gremlin-javascript/src/main/javascript/gremlin-javascript/test/cucumber/feature-steps.js +++ b/gremlin-javascript/src/main/javascript/gremlin-javascript/test/cucumber/feature-steps.js @@ -243,10 +243,10 @@ Then(/^the result should be (\w+)$/, function assertResult(characterizedAs, resu const expectedResult = resultTable.rows().map(row => parseRow.call(this, row)); switch (characterizedAs) { case 'ordered': - expect(expectedResult).to.have.deep.ordered.members(toCompare(this.result)); + expect(toCompare(this.result)).to.have.deep.ordered.members(expectedResult); break; case 'unordered': - expect(expectedResult).to.have.deep.members(toCompare(this.result)); + expect(toCompare(this.result)).to.have.deep.members(toCompare(expectedResult)); break; case 'of': // result is a subset of the expected