Skip to content

Commit

Permalink
Update snapshots with patch marks
Browse files Browse the repository at this point in the history
  • Loading branch information
thymikee committed Jan 9, 2017
1 parent d741f29 commit 538fb18
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 15 deletions.
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
exports[`.stringify() reduces maxDepth if stringifying very large objects 1`] = `"{"a": 1, "b": [Object]}"`;
exports[`.stringify() reduces maxDepth if stringifying very large objects 1`] = `"{\"a\": 1, \"b\": [Object]}"`;
exports[`.stringify() reduces maxDepth if stringifying very large objects 2`] = `"{"a": 1, "b": {"0": "test", "1": "test", "2": "test", "3": "test", "4": "test", "5": "test", "6": "test", "7": "test", "8": "test", "9": "test"}}"`;
exports[`.stringify() reduces maxDepth if stringifying very large objects 2`] = `"{\"a\": 1, \"b\": {\"0\": \"test\", \"1\": \"test\", \"2\": \"test\", \"3\": \"test\", \"4\": \"test\", \"5\": \"test\", \"6\": \"test\", \"7\": \"test\", \"8\": \"test\", \"9\": \"test\"}}"`;
exports[`.stringify() toJSON errors when comparing two objects 1`] = `
"expect(received).toEqual(expected)
Expected value to equal:
[32m{"b": 1, "toJSON": [Function toJSON]}[39m
[32m{\"b\": 1, \"toJSON\": [Function toJSON]}[39m
Received:
[31m{"a": 1, "toJSON": [Function toJSON]}[39m
[31m{\"a\": 1, \"toJSON\": [Function toJSON]}[39m
Difference:
- Expected
+ Received
@@ -1,4 +1,4 @@
 Object {
- "b": 1,
+ "a": 1,
 "toJSON": [Function toJSON],
 Object {
- \"b\": 1,
+ \"a\": 1,
 \"toJSON\": [Function toJSON],
 }"
`;
Original file line number Diff line number Diff line change
Expand Up @@ -1795,8 +1795,7 @@ Difference:
- Expected
+ Received

@@ -1,4 +1,4 @@
-<arrayContaining(Array [
-<arrayContaining(Array [
+Array [
 1,
- 2,
Expand Down Expand Up @@ -1845,8 +1844,7 @@ Difference:
- Expected
+ Received

@@ -1,3 +1,4 @@
-<objectContaining(Object {
-<objectContaining(Object {
- \"a\": 2,
-})>
+Object {
Expand Down
4 changes: 2 additions & 2 deletions packages/jest-matchers/src/matchers.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,12 @@ const matchers: MatchersObject = {
? () => matcherHint('.not.toBeCloseTo', 'received', 'expected, precision') + '\n\n' +
`Expected value not to be close to (with ${printExpected(precision)}-digit precision):\n` +
` ${printExpected(expected)}\n` +
`Received: \n` +
`Received:\n` +
` ${printReceived(actual)}`
: () => matcherHint('.toBeCloseTo', 'received', 'expected, precision') + '\n\n' +
`Expected value to be close to (with ${printExpected(precision)}-digit precision):\n` +
` ${printExpected(expected)}\n` +
`Received: \n` +
`Received:\n` +
` ${printReceived(actual)}`;

return {message, pass};
Expand Down

0 comments on commit 538fb18

Please sign in to comment.