December 2018
Intermediate to advanced
642 pages
15h 5m
English
What happens if a component has changed? Just for the sake of it, I made a pretty small change to a component. Upon running the tests, I got a FAIL message, with a comparison, that was produced by the usual diff command:
FAIL src/regionsApp/countryAndRegions.test.js ● App for Regions and Countries › renders correctly expect(value).toMatchSnapshot() Received value does not match stored snapshot 1. - Snapshot + Received @@ -7,11 +7,11 @@ loading={true} onSelect={[Function]} /> </div> <div> - Display: + Displays: <RegionsTable list={Array []} /> </div> </div> at Object.it (src/regionsApp/countryAndRegions.test.js:31:22) at new Promise (<anonymous>) at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)Read now
Unlock full access