bahaghari/tests/lib: add tests for tinted-theming subset

This commit is contained in:
Gabriel Arazas 2024-02-25 17:12:49 +08:00
parent e6b9d9e463
commit df345c8b51
No known key found for this signature in database
GPG Key ID: ADE0C41DAB221FCC
3 changed files with 52 additions and 0 deletions

View File

@ -2,7 +2,9 @@
let let
sampleBase16Scheme = lib.trivial.importYAML ./sample-base16-scheme.yml; sampleBase16Scheme = lib.trivial.importYAML ./sample-base16-scheme.yml;
sampleBase16Scheme' = lib.trivial.importYAML ./sample-base16-scheme-with-missing-colors.yml;
sampleBase24Scheme = lib.trivial.importYAML ./sample-base24-scheme.yml; sampleBase24Scheme = lib.trivial.importYAML ./sample-base24-scheme.yml;
sampleBase24Scheme' = lib.trivial.importYAML ./sample-base24-scheme-with-missing-colors.yml;
in in
pkgs.lib.runTests { pkgs.lib.runTests {
testIsBase16 = { testIsBase16 = {
@ -10,8 +12,18 @@ pkgs.lib.runTests {
expected = true; expected = true;
}; };
testIsNotBase16 = {
expr = lib.tinted-theming.isBase16 sampleBase16Scheme'.palette;
expected = false;
};
testIsBase24 = { testIsBase24 = {
expr = lib.tinted-theming.isBase24 sampleBase24Scheme.palette; expr = lib.tinted-theming.isBase24 sampleBase24Scheme.palette;
expected = true; expected = true;
}; };
testIsNotBase24 = {
expr = lib.tinted-theming.isBase24 sampleBase24Scheme'.palette;
expected = false;
};
} }

View File

@ -0,0 +1,19 @@
system: "base16"
name: "Bark on a tree"
author: "Gabriel Arazas (https://foodogsquared.one)"
variant: "dark"
description: "Rusty theme resembling forestry inspired from Nord theme."
palette:
base00: "2b221f"
base01: "412c26"
base02: "5c362c"
base03: "a45b43"
base04: "e1bcb2"
base05: "f5ecea"
base06: "fefefe"
base07: "eb8a65"
base08: "d03e68"
base09: "df937a"
base0A: "afa644"
base0E: "8b7ab9"
base0F: "7f3F83"

View File

@ -0,0 +1,21 @@
system: "base24"
name: "Flat"
author: "FredHappyface (https://github.com/fredHappyface)"
variant: "dark"
palette:
base00: "082845"
base01: "1d2845"
base02: "2e2e45"
base03: "444e5b"
base04: "68717b"
base05: "8c939a"
base06: "b0b6ba"
base07: "e7eced"
base08: "a82320"
base09: "e58d11"
base0A: "3c7dd2"
base0B: "2d9440"
base0C: "2c9370"
base0D: "3167ac"
base0E: "781aa0"
base0F: "541110"