[oe] [PATCH][meta-browser 2/2] cef3: comment out gtests completely

Martin Jansa martin.jansa at gmail.com
Wed Mar 16 15:47:42 UTC 2016


* the old fix wasn't enough and it was still failing with warnings
  about unused variables in gtests

Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
---
 ...-test.h-disable-warning-unused-definition.patch | 72 +++++++++++++++++++++-
 1 file changed, 70 insertions(+), 2 deletions(-)

diff --git a/recipes-browser/chromium/cef3/0003-gtest-typed-test.h-disable-warning-unused-definition.patch b/recipes-browser/chromium/cef3/0003-gtest-typed-test.h-disable-warning-unused-definition.patch
index 97a6116..a53dbc5 100644
--- a/recipes-browser/chromium/cef3/0003-gtest-typed-test.h-disable-warning-unused-definition.patch
+++ b/recipes-browser/chromium/cef3/0003-gtest-typed-test.h-disable-warning-unused-definition.patch
@@ -38,6 +38,74 @@ index fe1e83b..5053bbe 100644
 +#pragma GCC diagnostic pop
 +
  #endif  // GTEST_INCLUDE_GTEST_GTEST_TYPED_TEST_H_
--- 
-1.8.4.5
 
+diff -uNr a/base/test/sequenced_task_runner_test_template.h b/base/test/sequenced_task_runner_test_template.h
+--- a/base/test/sequenced_task_runner_test_template.h	2014-10-28 02:07:09.000000000 -1000
++++ b/base/test/sequenced_task_runner_test_template.h	2016-03-10 09:38:16.987413000 -1000
+@@ -23,6 +23,9 @@
+ #include "base/time/time.h"
+ #include "testing/gtest/include/gtest/gtest.h"
+ 
++#pragma GCC diagnostic push
++#pragma GCC diagnostic warning "-Wunused"
++
+ namespace base {
+ 
+ namespace internal {
+@@ -326,6 +329,7 @@
+ // whether the implementation supports nested tasks.
+ //
+ 
++/*
+ REGISTER_TYPED_TEST_CASE_P(SequencedTaskRunnerTest,
+                            SequentialNonNestable,
+                            SequentialNestable,
+@@ -335,6 +339,8 @@
+                            DelayedTasksSameDelay,
+                            DelayedTaskAfterLongTask,
+                            DelayedTaskAfterManyLongTasks);
++*/
++#pragma GCC diagnostic pop
+ 
+ }  // namespace base
+ 
+diff -uNr a/base/test/task_runner_test_template.h b/base/test/task_runner_test_template.h
+--- a/base/test/task_runner_test_template.h	2014-10-28 02:07:09.000000000 -1000
++++ b/base/test/task_runner_test_template.h	2016-03-10 09:39:02.051413000 -1000
+@@ -207,8 +207,10 @@
+             this->task_tracker_->GetTaskRunCounts());
+ }
+ 
++/*
+ REGISTER_TYPED_TEST_CASE_P(
+     TaskRunnerTest, Basic, Delayed, RunsTasksOnCurrentThread);
++*/
+ 
+ }  // namespace base
+ 
+diff -uNr a/testing/gtest/include/gtest/gtest-typed-test.h b/testing/gtest/include/gtest/gtest-typed-test.h
+--- a/testing/gtest/include/gtest/gtest-typed-test.h	2016-03-10 10:25:47.371413000 -1000
++++ b/testing/gtest/include/gtest/gtest-typed-test.h	2016-03-10 09:35:25.811413000 -1000
+@@ -34,6 +34,7 @@
+ 
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic warning "-Wunused"
++#pragma GCC diagnostic warning "-Wunused-variable"
+ 
+ // This header implements typed tests and type-parameterized tests.
+ 
+diff -uNr a/testing/gtest/include/gtest/gtest.h b/testing/gtest/include/gtest/gtest.h
+--- a/testing/gtest/include/gtest/gtest.h	2014-10-27 23:19:20.000000000 -1000
++++ b/testing/gtest/include/gtest/gtest.h	2016-03-10 09:36:13.607413000 -1000
+@@ -63,7 +63,11 @@
+ #include "gtest/gtest-printers.h"
+ #include "gtest/gtest_prod.h"
+ #include "gtest/gtest-test-part.h"
++#pragma GCC diagnostic push
++#pragma GCC diagnostic warning "-Wunused"
++#pragma GCC diagnostic warning "-Wunused-variable"
+ #include "gtest/gtest-typed-test.h"
++#pragma GCC diagnostic pop
+ 
+ // Depending on the platform, different string classes are available.
+ // On Linux, in addition to ::std::string, Google also makes use of
-- 
2.7.3




More information about the Openembedded-devel mailing list