From f389cc2a7d731e2dbd78e98a7d8e570049480261 Mon Sep 17 00:00:00 2001 From: Fuxing Loh <4266087+fuxingloh@users.noreply.github.com> Date: Thu, 20 Jun 2024 23:36:13 +0800 Subject: [PATCH] chore: minor refactor and fixes (#120) --- packages/chainfile-schema/schema.json | 3 ++- .../src/testcontainers.test.ts | 2 +- website/pages/core-concepts/4-step.mdx | 6 +++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/chainfile-schema/schema.json b/packages/chainfile-schema/schema.json index d9a3edc..820ccde 100644 --- a/packages/chainfile-schema/schema.json +++ b/packages/chainfile-schema/schema.json @@ -66,7 +66,8 @@ "additionalProperties": false } }, - "required": ["caip2", "name", "containers"] + "required": ["caip2", "name", "containers"], + "additionalProperties": false }, "ParamOptions": { "type": "object", diff --git a/packages/chainfile-testcontainers-node/src/testcontainers.test.ts b/packages/chainfile-testcontainers-node/src/testcontainers.test.ts index c9b31bf..ab7617c 100644 --- a/packages/chainfile-testcontainers-node/src/testcontainers.test.ts +++ b/packages/chainfile-testcontainers-node/src/testcontainers.test.ts @@ -143,7 +143,7 @@ describe('testcontainers.start()', () => { }); }); -describe('new ChainfileTestcontainers()', () => { +describe('new CFTestcontainers()', () => { it('should have different suffix', async () => { const file: Chainfile = { $schema: 'https://chainfile.org/schema.json', diff --git a/website/pages/core-concepts/4-step.mdx b/website/pages/core-concepts/4-step.mdx index ca6afc1..b354e06 100644 --- a/website/pages/core-concepts/4-step.mdx +++ b/website/pages/core-concepts/4-step.mdx @@ -35,7 +35,7 @@ Using containers to ensure your blockchain application integrates well with the ```ts filename="app.test.ts" import definition from '@chainfile/hardhat/localhost.json'; -const testcontainers = await ChainfileTestcontainers.start(definition); +const testcontainers = await CFTestcontainers.start(definition); ``` ### Deploy anywhere @@ -53,14 +53,14 @@ docker compose up With planet-scale cloud constructs that are future-proof to run on decentralized computing when ready. ```ts filename="cdk8s/chart.ts" {8-11} -import { ChainfileChart } from 'chainfile-cdk8s'; +import { CFChart } from 'chainfile-cdk8s'; import mainnet from '@chainfile/geth-lighthouse/mainnet.json'; class App extends Stack { constructor(scope: App, id: string, props?: StackProps) { super(scope, id, props); - new ChainfileChart(this, 'geth-lighthouse', { + new CFChart(this, 'geth-lighthouse', { definition: mainnet, spec: { replicas: 1 }, });