summaryrefslogtreecommitdiff
path: root/src/file_util_test.cc
blob: 3b1c3e23935b1e3129eb6631066916b703b9c8e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// Copyright 2018 Ryan Dahl <ry@tinyclouds.org>
// All rights reserved. MIT License.
#include "testing/gtest/include/gtest/gtest.h"

#include "file_util.h"

TEST(FileUtilTest, ReadFileToStringFileNotExist) {
  std::string output;
  EXPECT_FALSE(deno::ReadFileToString("/should_error_out.txt", &output));
}

// TODO(ry) success unit test. Needs a tempfile or fixture.
// TEST(FileUtilTest, ReadFileToStringSuccess) { }