chore: fix tests

This commit is contained in:
Rémi de Juvigny 2024-12-04 10:02:35 +01:00
parent 81b62a508e
commit 59cb734ff4
4 changed files with 5 additions and 16 deletions

View File

@ -14,5 +14,4 @@ runs:
env:
RUN_EE: ${{ inputs.runEE }}
JEST_OPTIONS: ${{ inputs.jestOptions }}
STRAPI_FEATURES_FUTURE_RELEASES_SCHEDULING: ${{ inputs.enableFutureFeatures }}
shell: bash

View File

@ -1,6 +1,5 @@
import { createStrapiInstance } from 'api-tests/strapi';
import { createAuthRequest } from 'api-tests/request';
import { describeOnCondition } from 'api-tests/utils';
import { createTestBuilder } from 'api-tests/builder';
const collectionTypeUid = 'api::product.product';
@ -41,11 +40,7 @@ const singleTypeModel = {
},
};
const edition = process.env.STRAPI_DISABLE_EE === 'true' ? 'CE' : 'EE';
// TODO: Remove skip when future flag is removed
// describeOnCondition(edition === 'EE')('Preview', () => {
describeOnCondition(false)('Preview', () => {
describe('Preview', () => {
const builder = createTestBuilder();
let strapi;
let rq;

View File

@ -1,6 +1,3 @@
module.exports = ({ env }) => ({
future: {
contentReleasesScheduling: env.bool('STRAPI_FEATURES_FUTURE_RELEASES_SCHEDULING', false),
preview: true,
},
future: {},
});

View File

@ -1,12 +1,10 @@
import { test, expect, Page } from '@playwright/test';
import { test, expect } from '@playwright/test';
import { login } from '../../utils/login';
import { resetDatabaseAndImportDataFromPath } from '../../utils/dts-import';
import { clickAndWait, describeOnCondition, findAndClose, skipCtbTour } from '../../utils/shared';
import { clickAndWait, findAndClose, skipCtbTour } from '../../utils/shared';
import { resetFiles } from '../../utils/file-reset';
const edition = process.env.STRAPI_DISABLE_EE === 'true' ? 'CE' : 'EE';
describeOnCondition(edition === 'EE')('Preview', () => {
test.describe('Preview', () => {
test.beforeEach(async ({ page }) => {
await resetDatabaseAndImportDataFromPath('with-admin.tar', (cts) => cts, { coreStore: false });
await resetFiles();