Skip to content

Commit f947a85

Browse files
committed
feat: bundle marketplace configs locally
1 parent 9260779 commit f947a85

8 files changed

Lines changed: 7376 additions & 320 deletions

File tree

‎src/.vscodeignore‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
!assets/vscode-material-icons/**
3232
!assets/icons/**
3333
!assets/images/**
34+
!assets/marketplace/**
3435

3536
# Include .env file for telemetry
3637
!.env

‎src/__tests__/dist_assets.spec.ts‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
import * as fs from "fs"
44
import * as path from "path"
5+
import * as yaml from "yaml"
56

67
describe("dist assets", () => {
78
const distPath = path.join(__dirname, "../dist")
9+
const marketplaceAssetsPath = path.join(__dirname, "../assets/marketplace")
810

911
describe("tiktoken", () => {
1012
it("should have tiktoken wasm file", () => {
@@ -56,4 +58,17 @@ describe("dist assets", () => {
5658
expect(fs.existsSync(path.join(distPath, filename))).toBe(true)
5759
})
5860
})
61+
62+
describe("marketplace assets", () => {
63+
const marketplaceFiles = ["modes.yml", "mcps.yml"]
64+
65+
test.each(marketplaceFiles)("should include bundled %s marketplace asset with multiple items", (filename) => {
66+
const assetPath = path.join(marketplaceAssetsPath, filename)
67+
expect(fs.existsSync(assetPath)).toBe(true)
68+
69+
const parsed = yaml.parse(fs.readFileSync(assetPath, "utf-8"))
70+
expect(Array.isArray(parsed?.items)).toBe(true)
71+
expect(parsed.items.length).toBeGreaterThan(1)
72+
})
73+
})
5974
})

0 commit comments

Comments
 (0)