Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(523)

Unified Diff: services/files/c/tests/util_unittest.cc

Issue 1133933002: Move //services/files/c -> //mojo/services/files/public/c. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: remove data dep Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « services/files/c/tests/test_utils_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/files/c/tests/util_unittest.cc
diff --git a/services/files/c/tests/util_unittest.cc b/services/files/c/tests/util_unittest.cc
deleted file mode 100644
index 680ff4a030b41fdec50e7aeee7a0483f3ecbf803..0000000000000000000000000000000000000000
--- a/services/files/c/tests/util_unittest.cc
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "services/files/c/lib/util.h"
-
-#include "mojo/public/cpp/system/macros.h"
-#include "mojo/services/files/public/interfaces/types.mojom.h"
-#include "testing/gtest/include/gtest/gtest.h"
-
-namespace mojio {
-namespace {
-
-// TODO(vtl): This test is pretty lame until |mojo::files::Error| can also
-// encapsulate "real" errno values.
-TEST(UtilTest, ErrorToErrno) {
- const struct ExpectedMapping {
- mojo::files::Error from;
- int to;
- } kExpectedMappings[] = {
- {mojo::files::ERROR_OK, 0},
- {mojo::files::ERROR_UNKNOWN, EIO},
- {mojo::files::ERROR_INVALID_ARGUMENT, EINVAL},
- {mojo::files::ERROR_PERMISSION_DENIED, EACCES},
- {mojo::files::ERROR_OUT_OF_RANGE, EINVAL},
- {mojo::files::ERROR_UNIMPLEMENTED, ENOSYS},
- {mojo::files::ERROR_CLOSED, EBADF},
- {mojo::files::ERROR_UNAVAILABLE, EACCES},
- {mojo::files::ERROR_INTERNAL, EIO},
- };
-
- for (size_t i = 0; i < MOJO_ARRAYSIZE(kExpectedMappings); i++) {
- const ExpectedMapping& m = kExpectedMappings[i];
- EXPECT_EQ(m.to, ErrorToErrno(m.from)) << "i=" << i << ", m.from=" << m.from;
- }
-}
-
-} // namespace
-} // namespace mojio
« no previous file with comments | « services/files/c/tests/test_utils_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698