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

Unified Diff: core/src/fxcrt/fx_basic_gcc_unittest.cpp

Issue 1755273002: Fix parsing of object numbers > 16,777,216. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 10 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
Index: core/src/fxcrt/fx_basic_gcc_unittest.cpp
diff --git a/core/src/fxcrt/fx_basic_gcc_unittest.cpp b/core/src/fxcrt/fx_basic_gcc_unittest.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..07cfe96570adcbab0c22af0e89301f73fc10e295
--- /dev/null
+++ b/core/src/fxcrt/fx_basic_gcc_unittest.cpp
@@ -0,0 +1,13 @@
+// Copyright 2014 PDFium 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 "core/include/fxcrt/fx_system.h"
+#include "testing/gtest/include/gtest/gtest.h"
+
Tom Sepez 2016/03/02 20:56:38 note: might be fun to cover the other FXYS_*toi()
dsinclair 2016/03/02 21:27:29 Done.
+TEST(fxcrt, FXSYS_atoui) {
+ EXPECT_EQ(0, FXSYS_atoui("0"));
+ EXPECT_EQ(2345, FXSYS_atoui("2345"));
+ EXPECT_EQ(4294967295, FXSYS_atoui("4294967295"));
+ EXPECT_EQ(4294967295, FXSYS_atoui("-1"));
+}

Powered by Google App Engine
This is Rietveld 408576698