What are we going to talk aboutwhat tools do we needwhat is test/kinds of testsgraphql - api connectionwhat are we going to test
GithubUsed to store code, has versioning so working together is not painful (sometimes still painful)git cheatsheet / tutorial
JavaScript/Node.js/npm/TypeScriptTests are written in JavaScript(TypeScript)we are using newest verion including new(ES6/ES2015) features Mozilla javascript documentation / articles
Node.js/npmNode.js is a non-browser environment, based on v8 engine (same as in Chrome)our tests will run in this enviromenthas it's own modules for backend use Node.js documentation
What is test/kinds of testssequence of actions followed by assertionit('should add 1 + 2 and get 3', () => { const result = 1 + 2; expect(result).toBe(3); });
Kinds of testsUnit testingIntegration testingSystem testingSanity testingSmoke testingInterface testingRegression testingBeta/Acceptance testing
Integration testingtesting application as a whole thingfor example for browser application this should emulate a user doing stuff on the pagein our case (API testing) we will send requests to our server and will check if response is correct
What are we going to testEmulating a client and send query to a graphql servergraphql server will send querires to REST API and generate a responsewe will "mock" responses from REST API and provide our own responses