summaryrefslogtreecommitdiffstats
path: root/apps/theming/tests
diff options
context:
space:
mode:
authorJulius Haertl <jus@bitgrid.net>2016-07-19 14:00:33 +0200
committerJulius Haertl <jus@bitgrid.net>2016-07-27 19:45:57 +0200
commitd07f04e4f761798a59ef1fc2545950ef4678c53e (patch)
treeba7b581f7df4bbd70411b4fe1bd59325abf2fbe3 /apps/theming/tests
parent0acfbd5b47487871eb50a91da0765aae5b6a9636 (diff)
downloadnextcloud-server-d07f04e4f761798a59ef1fc2545950ef4678c53e.tar.gz
nextcloud-server-d07f04e4f761798a59ef1fc2545950ef4678c53e.zip
Theming: Colorize checkboxes depending on luminance
Diffstat (limited to 'apps/theming/tests')
-rw-r--r--apps/theming/tests/lib/UtilTest.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/apps/theming/tests/lib/UtilTest.php b/apps/theming/tests/lib/UtilTest.php
index 9ebb11d6288..6451b65d027 100644
--- a/apps/theming/tests/lib/UtilTest.php
+++ b/apps/theming/tests/lib/UtilTest.php
@@ -65,4 +65,14 @@ class UtilTest extends TestCase {
$invert = Util::invertTextColor('');
$this->assertEquals(false, $invert);
}
+
+ public function testElementColorDefault() {
+ $elementColor = Util::elementColor("#000000");
+ $this->assertEquals('#000000', $elementColor);
+ }
+
+ public function testElementColorOnBrightBackground() {
+ $elementColor = Util::elementColor('#ffffff');
+ $this->assertEquals('#969696', $elementColor);
+ }
}