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

Unified Diff: mojo/android/javatests/src/org/chromium/mojo/TestUtils.java

Issue 306893010: Generate java bindings for structs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Follow review Created 6 years, 6 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: mojo/android/javatests/src/org/chromium/mojo/TestUtils.java
diff --git a/mojo/android/javatests/src/org/chromium/mojo/TestUtils.java b/mojo/android/javatests/src/org/chromium/mojo/TestUtils.java
new file mode 100644
index 0000000000000000000000000000000000000000..a397be3a580a0e1f826b70406fdab54be486f912
--- /dev/null
+++ b/mojo/android/javatests/src/org/chromium/mojo/TestUtils.java
@@ -0,0 +1,24 @@
+// Copyright 2014 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.
+
+package org.chromium.mojo;
+
+import junit.framework.TestCase;
+
+import java.util.Arrays;
+
+/**
+ * Utilities methods for tests.
+ */
+public final class TestUtils {
+
+ /**
+ * Tests that 2 arrays are equals, recursively using this method is the arrays themselves
+ * contain arrays.
+ */
+ public static void assertArrayEquals(Object a, Object b) {
+ TestCase.assertTrue(Arrays.deepEquals(new Object[] { a }, new Object[] { b }));
+ }
+
+}

Powered by Google App Engine
This is Rietveld 408576698