1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-09-05 17:53:12 +02:00

Wip: Add commented-out test for variants property.

This commit is contained in:
Thomas Heartman 2022-07-19 12:10:10 +02:00
parent f4ed7d0893
commit f7d57c829e

View File

@ -154,4 +154,46 @@ describe('the playground service (e2e)', () => {
testParams,
);
});
test('returned list of variants is always the same as the one that goes in', async () => {
// await fc.assert(
// fc
// .asyncProperty(
// clientFeatures({ minLength: 1 }),
// generateContext(),
// async (toggles, context) => {
// await Promise.all(
// toggles.map((feature) =>
// stores.featureToggleStore.create(
// feature.project,
// {
// ...feature,
// createdAt: new Date(feature.createdAt),
// },
// ),
// ),
// );
// const projects = '*';
// const env = 'default';
// const serviceToggles: PlaygroundFeatureSchema[] =
// await service.evaluateQuery(projects, env, context);
// const ts = toggles.reduce(
// (acc, t) => ({
// ...acc,
// [t.name]: t,
// }),
// {},
// );
// return serviceToggles.every((feature) => {
// feature.variants.length ===
// ts[feature.name].variants.length;
// });
// },
// )
// .afterEach(async () => {
// await stores.featureToggleStore.deleteAll();
// }),
// testParams,
// );
});
});