mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
Added test to test default theme against linked gscan version (#19020)
fixes GRO-32 If we ever introduce errors in the linked source theme and linked gscan version combination, this test will catch it.
This commit is contained in:
parent
a2cd4445f3
commit
e3cdc24d6b
3 changed files with 17 additions and 1 deletions
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
@ -591,6 +591,8 @@ jobs:
|
|||
name: Regression tests (Node ${{ matrix.node }}, ${{ matrix.env.DB }})
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: true
|
||||
- uses: actions/setup-node@v4
|
||||
env:
|
||||
FORCE_COLOR: 0
|
||||
|
|
|
@ -49,7 +49,7 @@ export default [
|
|||
setting('site', 'twitter_description', null),
|
||||
|
||||
// THEME
|
||||
setting('theme', 'active_theme', 'Source'),
|
||||
setting('theme', 'active_theme', 'source'),
|
||||
|
||||
// PRIVATE
|
||||
setting('private', 'is_private', false),
|
||||
|
|
14
ghost/core/test/regression/site/default-theme.test.js
Normal file
14
ghost/core/test/regression/site/default-theme.test.js
Normal file
|
@ -0,0 +1,14 @@
|
|||
const assert = require('assert/strict');
|
||||
const {mockSetting} = require('../../utils/e2e-framework-mock-manager');
|
||||
|
||||
// This test checks if the default theme passes the current gscan version
|
||||
// If this test fails, check the used gscan version in Ghost
|
||||
it('Default theme passes linked gscan version', async function () {
|
||||
const themeService = require('../../../core/server/services/themes');
|
||||
|
||||
// Set active theme name
|
||||
mockSetting('active_theme', 'source');
|
||||
await themeService.init();
|
||||
const theme = await themeService.api.getThemeErrors('source');
|
||||
assert.deepEqual(theme.errors, [], 'Default theme should have no errors');
|
||||
});
|
Loading…
Add table
Reference in a new issue