From 704434f7ae287e4212e70a0144cf312c2ee297af Mon Sep 17 00:00:00 2001 From: Ping Yu <4018+pyu10055@users.noreply.github.com> Date: Thu, 2 Jul 2020 13:25:54 -0700 Subject: [PATCH 1/2] use array close --- tfjs-core/src/ops/max_test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tfjs-core/src/ops/max_test.ts b/tfjs-core/src/ops/max_test.ts index 147bd131c78..61c1cc3388a 100644 --- a/tfjs-core/src/ops/max_test.ts +++ b/tfjs-core/src/ops/max_test.ts @@ -97,7 +97,7 @@ describeWithFlags('max', ALL_ENVS, () => { tf.max(input, [1, 0]); const inputDataAfter = await input.data(); - expectArraysEqual(inputDataBefore, inputDataAfter); + expectArraysClose(inputDataBefore, inputDataAfter); }); it('throws when passed a non-tensor', () => { From cb7d06d7f555d499d19f0d400803b8d4d7f4dc24 Mon Sep 17 00:00:00 2001 From: Ping Yu <4018+pyu10055@users.noreply.github.com> Date: Thu, 2 Jul 2020 14:15:09 -0700 Subject: [PATCH 2/2] fix lint --- tfjs-core/src/ops/max_test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tfjs-core/src/ops/max_test.ts b/tfjs-core/src/ops/max_test.ts index 61c1cc3388a..f48f4cf7567 100644 --- a/tfjs-core/src/ops/max_test.ts +++ b/tfjs-core/src/ops/max_test.ts @@ -17,7 +17,7 @@ import * as tf from '../index'; import {ALL_ENVS, describeWithFlags} from '../jasmine_util'; -import {expectArraysClose, expectArraysEqual} from '../test_util'; +import {expectArraysClose} from '../test_util'; describeWithFlags('max', ALL_ENVS, () => { it('with one element dominating', async () => {