From ac188833fd16f09d109fb420aa2d24d0505da917 Mon Sep 17 00:00:00 2001 From: Carlos Cortizas <97907068+CarlosCortizasCT@users.noreply.github.com> Date: Tue, 19 Nov 2024 10:59:55 +0100 Subject: [PATCH] Fix Channel data model compat mode presets (#715) * fix(channel): fix compatibility model presets * chore: add changeset --- .changeset/giant-pans-fly.md | 6 ++++++ models/channel/src/index.ts | 2 +- models/channel/src/presets/index.ts | 4 ++++ 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 .changeset/giant-pans-fly.md diff --git a/.changeset/giant-pans-fly.md b/.changeset/giant-pans-fly.md new file mode 100644 index 000000000..53d5bf766 --- /dev/null +++ b/.changeset/giant-pans-fly.md @@ -0,0 +1,6 @@ +--- +'@commercetools-test-data/channel': patch +--- + +Fixes the exported presets for the compatibility test data model. +We were exporting the GraphQL ones so it was not possible to generate REST data models out of them. diff --git a/models/channel/src/index.ts b/models/channel/src/index.ts index 02fa5d13a..4b9b6186b 100644 --- a/models/channel/src/index.ts +++ b/models/channel/src/index.ts @@ -25,4 +25,4 @@ export const ChannelGraphql = { * @deprecated Use `ChannelRest` or `ChannelGraphql` exported models instead of `Channel`. */ export const random = CompatChannelModelBuilder; -export const presets = modelPresets.graphqlPresets; +export const presets = modelPresets.compatPresets; diff --git a/models/channel/src/presets/index.ts b/models/channel/src/presets/index.ts index 3ac9fffbd..728019966 100644 --- a/models/channel/src/presets/index.ts +++ b/models/channel/src/presets/index.ts @@ -9,3 +9,7 @@ export const graphqlPresets = { foodStore: foodStore.graphqlPreset, clothesStore: clothesStore.graphqlPreset, }; +export const compatPresets = { + foodStore: foodStore.compatPreset, + clothesStore: clothesStore.compatPreset, +};