Make use of ::testing::TempDir to access tmp dir.

PiperOrigin-RevId: 275115437
Change-Id: I10fcec58c9ebcc447f56306501447cab92cc29f3
This commit is contained in:
Brian Atkinson 2019-10-16 14:34:03 -07:00 committed by TensorFlower Gardener
parent 7874c7034c
commit 1c88fff548
2 changed files with 1 additions and 5 deletions

View File

@ -38,9 +38,6 @@ tf_cc_test(
"//tensorflow/lite:testdata/add.bin",
"//tensorflow/lite:testdata/test_input.csv",
],
tags = [
"no_oss",
],
deps = [
":util",
"//tensorflow/lite/testing:tflite_driver",

View File

@ -18,7 +18,6 @@ limitations under the License.
#include <memory>
#include <gmock/gmock.h>
#include "testing/base/public/googletest.h"
#include <gtest/gtest.h>
#include "tensorflow/lite/testing/tflite_driver.h"
@ -32,7 +31,7 @@ TEST(UtilTest, SimpleE2ETest) {
options.tflite_model = "tensorflow/lite/testdata/add.bin";
options.read_input_from_file =
"tensorflow/lite/testdata/test_input.csv";
options.dump_output_to_file = FLAGS_test_tmpdir + "/test_out.csv";
options.dump_output_to_file = ::testing::TempDir() + "/test_out.csv";
options.kernel_type = "REFERENCE";
std::unique_ptr<TestRunner> runner(new TfLiteDriver(
TfLiteDriver::DelegateType::kNone, /*reference_kernel=*/true));