11import { test , expect } from '@playwright/test' ;
2- import { asRGB , checkBorderProperties , checkColor , getCSSProperty } from '../src/utils' ;
32
43test ( 'Dark and light brand after user themes' , async ( { page } ) => {
54 // This document use a custom theme file that change the background color of the title banner
@@ -25,24 +24,3 @@ test('Dark and light brand before user themes', async ({ page }) => {
2524 const locatr2 = await page . locator ( 'body' ) . first ( ) ;
2625 await expect ( locatr2 ) . toHaveCSS ( 'background-color' , 'rgb(6, 6, 6)' ) ;
2726} ) ;
28-
29- test . use ( { javaScriptEnabled : false } ) ;
30-
31- test ( 'Dark brand default, no JS' , async ( { page } ) => {
32- // This document use a custom theme file that change the background color of the title banner
33- // Same user defined color should be used in both dark and light theme
34- await page . goto ( './html/dark-brand/brand-after-theme.html' ) ;
35- const locatr = await page . locator ( 'body' ) . first ( ) ;
36- await expect ( locatr ) . toHaveClass ( 'fullcontent quarto-dark' ) ;
37- await expect ( locatr ) . toHaveCSS ( 'background-color' , 'rgb(66, 7, 11)' ) ;
38- } ) ;
39-
40-
41- test ( 'Light brand default, no JS' , async ( { page } ) => {
42- // This document use a custom theme file that change the background color of the title banner
43- // Same user defined color should be used in both dark and light theme
44- await page . goto ( './html/dark-brand/brand-before-theme.html' ) ;
45- const locatr = await page . locator ( 'body' ) . first ( ) ;
46- await expect ( locatr ) . toHaveClass ( 'fullcontent quarto-light' ) ;
47- await expect ( locatr ) . toHaveCSS ( 'background-color' , 'rgb(252, 252, 252)' ) ;
48- } ) ;
0 commit comments