Skip to content

Commit

Permalink
Remove unecessary comments
Browse files Browse the repository at this point in the history
  • Loading branch information
dubzzz committed Mar 14, 2019
1 parent f7421c3 commit 856b356
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ describe('toContain', () => {
fc.array(fc.anything(anythingSettings)),
fc.anything(anythingSettings).filter(v => !Number.isNaN(v)),
(startValues, endValues, v) => {
// Given: startValues, endValues arrays and v value (not NaN)
// Assert: We expect `expect([...startValues, v, ...endValues]).toContain(v)`
// Given: startValues, endValues arrays and v value (not NaN)
expect([...startValues, v, ...endValues]).toContain(v);
},
),
Expand All @@ -36,10 +35,9 @@ describe('toContain', () => {
fc.array(fc.anything(anythingSettings)),
fc.dedup(fc.anything(anythingSettings), 2),
(startValues, endValues, [a, b]) => {
// Given: startValues, endValues arrays
// and [a, b] equal, but not the same values
// with `typeof a === 'object && a !== null`
// Assert: We expect `expect([...startValues, a, ...endValues]).not.toContain(b)`
// Given: startValues, endValues arrays
// and [a, b] equal, but not the same values
// with `typeof a === 'object && a !== null`
fc.pre(typeof a === 'object' && a !== null);
expect([...startValues, a, ...endValues]).not.toContain(b);
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ describe('toContainEqual', () => {
fc.array(fc.anything(anythingSettings)),
fc.anything(anythingSettings),
(startValues, endValues, v) => {
// Given: startValues, endValues arrays and v any value
// Assert: We expect `expect([...startValues, v, ...endValues]).toContainEqual(v)`
// Given: startValues, endValues arrays and v any value
expect([...startValues, v, ...endValues]).toContainEqual(v);
},
),
Expand All @@ -36,9 +35,8 @@ describe('toContainEqual', () => {
fc.array(fc.anything(anythingSettings)),
fc.dedup(fc.anything(anythingSettings), 2),
(startValues, endValues, [a, b]) => {
// Given: startValues, endValues arrays
// and [a, b] identical values
// Assert: We expect `expect([...startValues, a, ...endValues]).toContainEqual(b)`
// Given: startValues, endValues arrays
// and [a, b] identical values
expect([...startValues, a, ...endValues]).toContainEqual(b);
},
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ describe('toEqual', () => {
it('should be reflexive', () => {
fc.assert(
fc.property(fc.dedup(fc.anything(anythingSettings), 2), ([a, b]) => {
// Given: a and b identical values
// Assert: We expect `expect(a).toEqual(b)`
// Given: a and b identical values
expect(a).toEqual(b);
}),
assertSettings,
Expand All @@ -38,7 +37,7 @@ describe('toEqual', () => {
fc.anything(anythingSettings),
fc.anything(anythingSettings),
(a, b) => {
// Given: a and b values
// Given: a and b values
// Assert: We expect `expect(a).toEqual(b)`
// to be equivalent to `expect(b).toEqual(a)`
expect(safeExpectEqual(a, b)).toBe(safeExpectEqual(b, a));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ describe('toStrictEqual', () => {
it('should be reflexive', () => {
fc.assert(
fc.property(fc.dedup(fc.anything(anythingSettings), 2), ([a, b]) => {
// Given: a and b identical values
// Assert: We expect `expect(a).toStrictEqual(b)`
// Given: a and b identical values
expect(a).toStrictEqual(b);
}),
assertSettings,
Expand All @@ -27,7 +26,7 @@ describe('toStrictEqual', () => {
it('should be symmetric', () => {
const safeExpectStrictEqual = (a, b) => {
try {
expect(a).toEqual(b);
expect(a).toStrictEqual(b);
return true;
} catch (err) {
return false;
Expand Down

0 comments on commit 856b356

Please sign in to comment.