[XLA] Fix reduce test to actually use the specified input

PiperOrigin-RevId: 284644242
Change-Id: I84f2181660aeb80e75e42407aa49a4391a535433
This commit is contained in:
A. Unique TensorFlower 2019-12-09 15:09:57 -08:00 committed by TensorFlower Gardener
parent 7480d49690
commit d26ba01420

View File

@ -106,7 +106,10 @@ XLA_TEST_P(ReduceWithLayoutTest, Reduce) {
{-0.241772294, -0.245131493, -0.160247207}, {-0.241772294, -0.245131493, -0.160247207},
{-0.179881215, -0.23383224, -0.121976733}}}}); {-0.179881215, -0.23383224, -0.121976733}}}});
EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); auto reduce_input_relaid =
reduce_input.Relayout(reduce_input_shape->layout());
EXPECT_TRUE(RunAndCompareNoHloPasses(
std::move(module), {&reduce_input_relaid}, ErrorSpec(1e-5)));
} }
INSTANTIATE_TEST_CASE_P(ReduceWithLayoutTest_Instantiation, INSTANTIATE_TEST_CASE_P(ReduceWithLayoutTest_Instantiation,