diff options
| author | Wes Bos <wesbos@gmail.com> | 2018-04-20 15:41:42 -0400 |
|---|---|---|
| committer | Wes Bos <wesbos@gmail.com> | 2018-04-20 15:41:42 -0400 |
| commit | 50c68a28bf877ec24bfa5c18bdb63b30477c407e (patch) | |
| tree | 10550716ff150e2adf69f25b6b340fb563770427 /frontend/__tests__/__snapshots__ | |
| parent | 426aba70f5addfd3c6c1a972ced18395683feae9 (diff) | |
Single Item Test
Diffstat (limited to 'frontend/__tests__/__snapshots__')
| -rw-r--r-- | frontend/__tests__/__snapshots__/SingleItem.test.js.snap | 44 |
1 files changed, 28 insertions, 16 deletions
diff --git a/frontend/__tests__/__snapshots__/SingleItem.test.js.snap b/frontend/__tests__/__snapshots__/SingleItem.test.js.snap index 09eb52b..4d75565 100644 --- a/frontend/__tests__/__snapshots__/SingleItem.test.js.snap +++ b/frontend/__tests__/__snapshots__/SingleItem.test.js.snap @@ -1,5 +1,19 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`<SingleItem/> Errors with a not found Item 1`] = ` +<p + data-test="graphql-error" +> + <strong> + Shoot! + </strong> + Item not found! + <button> + Try Again + </button> +</p> +`; + exports[`<SingleItem/> Renders with Proper Data 1`] = ` Array [ <styled.div @@ -9,33 +23,32 @@ Array [ className="sc-bwzfXH dFvSZo" data-test="SingleItem" > - <DisplayError /> <img - alt="Facilis corporis" - src="large-dog.jpg" + alt="dogs are best" + src="dog.jpg" /> <div className="details" > <h2> Viewing - Facilis corporis + dogs are best </h2> <p> - Quidem praesentium magnam. Error molestiae laborum est possimus assumenda aut enim iure. Ut explicabo iure vitae occaecati officia iure nisi. + dogs </p> <Link href={ Object { - "pathname": "/admin/update", + "pathname": "/update", "query": Object { - "id": "5505a740-e67e-4e17-958f-46760116bcd2", + "id": "123", }, } } > <a - href="/admin/update?id=5505a740-e67e-4e17-958f-46760116bcd2" + href="/update?id=123" onClick={[Function]} > Edit ✏️ @@ -48,33 +61,32 @@ Array [ className="sc-bwzfXH dFvSZo" data-test="SingleItem" > - <DisplayError /> <img - alt="Facilis corporis" - src="large-dog.jpg" + alt="dogs are best" + src="dog.jpg" /> <div className="details" > <h2> Viewing - Facilis corporis + dogs are best </h2> <p> - Quidem praesentium magnam. Error molestiae laborum est possimus assumenda aut enim iure. Ut explicabo iure vitae occaecati officia iure nisi. + dogs </p> <Link href={ Object { - "pathname": "/admin/update", + "pathname": "/update", "query": Object { - "id": "5505a740-e67e-4e17-958f-46760116bcd2", + "id": "123", }, } } > <a - href="/admin/update?id=5505a740-e67e-4e17-958f-46760116bcd2" + href="/update?id=123" onClick={[Function]} > Edit ✏️ |
