diff --git a/.changeset/shiny-crabs-grin.md b/.changeset/shiny-crabs-grin.md new file mode 100644 index 0000000000..04e5328e3c --- /dev/null +++ b/.changeset/shiny-crabs-grin.md @@ -0,0 +1,5 @@ +--- +"create-lz-oapp": patch +--- + +relabel example labels for OFT and OFT (Solana) diff --git a/examples/oft-solana/README.md b/examples/oft-solana/README.md index b773a558cd..ee250f32c1 100644 --- a/examples/oft-solana/README.md +++ b/examples/oft-solana/README.md @@ -57,7 +57,7 @@ Create your local copy of this example: ```bash -LZ_ENABLE_SOLANA_OFT_EXAMPLE=1 pnpm dlx create-lz-oapp@latest +pnpm dlx create-lz-oapp@latest ``` Specify the directory, select `OFT (Solana)` and proceed with the installation. diff --git a/packages/create-lz-oapp/src/config.ts b/packages/create-lz-oapp/src/config.ts index 72ff9ca197..2f95b64311 100644 --- a/packages/create-lz-oapp/src/config.ts +++ b/packages/create-lz-oapp/src/config.ts @@ -25,9 +25,16 @@ export const getExamples = (): Example[] => { directory: 'examples/oapp', ref, }, + { + id: 'oft-solana', + label: 'OFT - EVM, Solana', + repository, + directory: 'examples/oft-solana', + ref, + }, { id: 'oft', - label: 'OFT', + label: 'OFT - EVM only', repository, directory: 'examples/oft', ref, @@ -149,18 +156,6 @@ export const getExamples = (): Example[] => { }, ] : []), - // The Solana OFT example is feature flagged for the time being - ...(process.env.LZ_ENABLE_SOLANA_OFT_EXAMPLE - ? [ - { - id: 'oft-solana', - label: 'OFT (Solana)', - repository, - directory: 'examples/oft-solana', - ref, - }, - ] - : []), ...(process.env.LZ_ENABLE_SOLANA_OAPP_EXAMPLE ? [ { diff --git a/packages/create-lz-oapp/test/config.test.ts b/packages/create-lz-oapp/test/config.test.ts index 74fc36c612..2e94bd7bb1 100644 --- a/packages/create-lz-oapp/test/config.test.ts +++ b/packages/create-lz-oapp/test/config.test.ts @@ -40,15 +40,7 @@ describe('config', () => { examples.forEach((example) => expect(example).toMatchObject({ ref: 'ohhello' })) }) - it('should not include Solana OFT example if LZ_ENABLE_SOLANA_OFT_EXAMPLE is empty', () => { - process.env.LZ_ENABLE_SOLANA_OFT_EXAMPLE = '' - - expect(getExamples()).not.toContainEqual(expect.objectContaining({ id: 'oft-solana' })) - }) - - it('should include Solana OFT example if LZ_ENABLE_SOLANA_OFT_EXAMPLE is defined', () => { - process.env.LZ_ENABLE_SOLANA_OFT_EXAMPLE = 'yes' - + it('should include Solana OFT example', () => { expect(getExamples()).toContainEqual(expect.objectContaining({ id: 'oft-solana' })) }) diff --git a/tests-user/tests/create-lz-oapp.bats b/tests-user/tests/create-lz-oapp.bats index 74710a59d3..683a239207 100644 --- a/tests-user/tests/create-lz-oapp.bats +++ b/tests-user/tests/create-lz-oapp.bats @@ -194,7 +194,7 @@ teardown() { @test "should work with pnpm & oft solana example in CI mode" { local DESTINATION="$PROJECTS_DIRECTORY/pnpm-oft-solana" - LZ_ENABLE_SOLANA_OFT_EXAMPLE=1 npx --yes create-lz-oapp --ci --example oft-solana --destination $DESTINATION --package-manager pnpm + npx --yes create-lz-oapp --ci --example oft-solana --destination $DESTINATION --package-manager pnpm cd "$DESTINATION" pnpm compile pnpm test diff --git a/turbo.json b/turbo.json index 420acc6970..92e5cc9082 100644 --- a/turbo.json +++ b/turbo.json @@ -56,7 +56,6 @@ "LZ_ENABLE_EXPERIMENTAL_PARALLEL_EXECUTION", "LZ_ENABLE_EXPERIMENTAL_RETRY", "LZ_ENABLE_EXPERIMENTAL_SIMULATION", - "LZ_ENABLE_SOLANA_OFT_EXAMPLE", "LZ_ENABLE_SOLANA_OAPP_EXAMPLE", "LZ_ENABLE_READ_EXAMPLE", "LZ_ENABLE_ZKSOLC_EXAMPLE",