Skip to content

Instantly share code, notes, and snippets.

@goldbergyoni
Created December 23, 2018 19:10
Show Gist options
  • Save goldbergyoni/4657e9dca21f938b1549694c85aceb72 to your computer and use it in GitHub Desktop.
Save goldbergyoni/4657e9dca21f938b1549694c85aceb72 to your computer and use it in GitHub Desktop.
A test that one can read without leaving and visiting external code
it("When getting orders report, get the existing orders", () => {
//This one hopefully is telling a direct and explicit story
const orderWeJustAdded = ordersTestHelpers.addRandomNewOrder();
const queryObject = newQueryObject(config.DBInstanceURL, queryOptions.deep, useCache:false);
const result = queryObject.query(config.adminUserToken, reports.orders, pageSize:200);
expect(result).to.be.an('array').that.does.include(orderWeJustAdded);
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment