Index: base/functional_unittest.cc |
diff --git a/base/functional_unittest.cc b/base/functional_unittest.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..e0c3100ed9f90fa7b4065502f7e249c0fc1d3578 |
--- /dev/null |
+++ b/base/functional_unittest.cc |
@@ -0,0 +1,23 @@ |
+// Copyright 2017 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 "base/functional.h" |
+ |
+#include "base/containers/container_test_utils.h" |
+#include "testing/gtest/include/gtest/gtest.h" |
+ |
+namespace base { |
+ |
+namespace { |
+ |
+TEST(Functional, Less) { |
+ using ExplicitInt = base::MoveOnlyInt; |
+ EXPECT_TRUE(base::less()(ExplicitInt(3), 4)); |
+ EXPECT_FALSE(base::less()(4, ExplicitInt(3))); |
+ EXPECT_TRUE(base::less()(3, 4)); |
+} |
+ |
+} // namespace |
+ |
+} // namespace base |