aboutsummaryrefslogtreecommitdiff
path: root/tests/integration
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2022-02-18 08:28:17 +0100
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2022-02-18 08:28:17 +0100
commite3049a5c9ef52e052a756b9ffbfcb3e0c35ab326 (patch)
treedae68f1052a0c848bc9f22542fb170d8a93acf45 /tests/integration
parent4d324593cd1af2c11fab2b0b85f9dc6bffc649e9 (diff)
parentd61f8357fd7a8fbbd5eeaf594863a92401d25693 (diff)
downloadayatana-indicator-sound-e3049a5c9ef52e052a756b9ffbfcb3e0c35ab326.tar.gz
ayatana-indicator-sound-e3049a5c9ef52e052a756b9ffbfcb3e0c35ab326.tar.bz2
ayatana-indicator-sound-e3049a5c9ef52e052a756b9ffbfcb3e0c35ab326.zip
Merge branch 'tari01-pr/build-with-werror'
Attributes GH PR #77: https://github.com/AyatanaIndicators/ayatana-indicator-sound/pull/77
Diffstat (limited to 'tests/integration')
-rw-r--r--tests/integration/test-indicator.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/integration/test-indicator.cpp b/tests/integration/test-indicator.cpp
index cbf1c6d..624176a 100644
--- a/tests/integration/test-indicator.cpp
+++ b/tests/integration/test-indicator.cpp
@@ -1,6 +1,6 @@
/*
* Copyright 2015 Canonical Ltd.
- * Copyright 2021 Robert Tari
+ * Copyright 2021-2022 Robert Tari
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 3, as published
@@ -276,8 +276,8 @@ TEST_F(TestIndicator, DISABLED_PhoneChangeRoleVolume)
// Generate a random volume in the range [0...0.33]
QTime now = QTime::currentTime();
- qsrand(now.msec());
- int randInt = qrand() % 33;
+ QRandomGenerator::global()->bounded(now.msec());
+ int randInt = QRandomGenerator::global()->generate() % 33;
const double randomVolume = randInt / 100.0;
QSignalSpy &userAccountsSpy = *signal_spy_volume_changed_;
@@ -1412,8 +1412,8 @@ TEST_F(TestIndicator, DISABLED_DesktopChangeRoleVolume)
// Generate a random volume in the range [0...0.33]
QTime now = QTime::currentTime();
- qsrand(now.msec());
- int randInt = qrand() % 33;
+ QRandomGenerator::global()->bounded(now.msec());
+ int randInt = QRandomGenerator::global()->generate() % 33;
const double randomVolume = randInt / 100.0;
// play a test sound, it should NOT change the role in the indicator