Forwarded upstream: https://lists.gnu.org/archive/html/jami/2024-01/msg00010.html From 1d3b044c85c32341cca392254fe8bbf34a4639e1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 9 Jan 2024 11:14:04 -0500 Subject: [PATCH] tests: Skip tests that need Internet when there's none. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * tests/unittests/messageparser_unittest.cpp (ALinkIsParsedCorrectly) (YoutubeLinkIsParsedCorrectly): Skip when there is no Internet. Series-to: jami@gnu.org Series-cc: Sébastien Blin Fixes: Change-Id: I0a5b57cd82f93fd7edf3fbeb73fb3db5a04c628c --- tests/unittests/messageparser_unittest.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/unittests/messageparser_unittest.cpp b/tests/unittests/messageparser_unittest.cpp index c10b0d0b..df7a0692 100644 --- a/tests/unittests/messageparser_unittest.cpp +++ b/tests/unittests/messageparser_unittest.cpp @@ -69,6 +69,9 @@ TEST_F(MessageParserFixture, TextIsParsedCorrectly) */ TEST_F(MessageParserFixture, ALinkIsParsedCorrectly) { + if (!globalEnv.connectivityMonitor->isOnline()) + GTEST_SKIP() << "ALinkIsParsedCorrectly requires Internet connectivity"; + auto linkColor = QColor::fromRgb(0, 0, 255); auto backgroundColor = QColor::fromRgb(0, 0, 255); @@ -174,6 +177,9 @@ TEST_F(MessageParserFixture, FencedCodeIsParsedCorrectly) */ TEST_F(MessageParserFixture, YoutubeLinkIsParsedCorrectly) { + if (!globalEnv.connectivityMonitor->isOnline()) + GTEST_SKIP() << "YoutubeLinkIsParsedCorrectly requires Internet connectivity"; + auto url = "https://www.youtube.com/watch?v=1234567890"; auto msg = "blah blah " + QString(url) + " blah blah"; base-commit: a4300308dc8d03d59f620bb5fed753df5cf31ed9 prerequisite-patch-id: 90a419e7de1f4fa5bb68bc58ad0da2817ed268e0 -- 2.41.0 tr>
AgeCommit message (Expand)Author
2021-08-10gnu: gcompris-qt: Switch to qt-build-system....* gnu/packages/education.scm (gcompris-qt)[build-system]: Switch from cmake-build-system to qt-build-system. [arguments]: Remove custom 'wrap-executable phase. Efraim Flashner
2021-08-10gnu: gcompris-qt: Update to 1.1....* gnu/packages/education.scm (gcompris-qt): Update to 1.1. Efraim Flashner
2021-07-29gnu: snap: Update to 6.9.0....* gnu/packages/education.scm (snap): Update to 6.9.0. Nicolas Goaziou
2021-07-04gnu: fet: Update to 6.0.4....* gnu/packages/education.scm (fet): Update to 6.0.4. [inputs]: Use Qt 6. Nicolas Goaziou
2021-07-03gnu: Add gotypist....* gnu/packages/education.scm (gotypist): New public variable. Tobias Geerinckx-Rice
2021-06-14gnu: Rename qtbase to qtbase-5....This change was automated via the following command: $ git ls-files | xargs sed -i 's/,qtbase)/,qtbase-5)/g' $ git ls-files | xargs sed -i 's/inherit qtbase)/inherit qtbase-5)/g' $ git ls-files | xargs sed -i 's/package-version qtbase)/package-version qtbase-5)/g' $ git checkout etc # to clear some spurious changes This is done so the qtbase package can be upgraded to version 6 in the following commit. Maxim Cournoyer
2021-06-11gnu: klavaro: Update to 3.13....* gnu/packages/education.scm (klavaro): Update to 3.13. Tobias Geerinckx-Rice
2021-05-25gnu: Add kanatest....* gnu/packages/education.scm (kanatest): New variable. Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr> nixo