Skip to content
This repository has been archived by the owner on Aug 24, 2023. It is now read-only.

refactor(packages): move to a single root package.json with turbo pipelines #42

Merged
merged 8 commits into from
Aug 31, 2022

Conversation

fuxingloh
Copy link
Contributor

@fuxingloh fuxingloh commented Aug 30, 2022

What this PR does / why we need it:

Move docs into packages/* and refactor node projects to use @birthdayresearch/sticky. Move to a single root package.json with turbo pipelines. Configure to use @birthdayresearch/*. (Mainly to utilize sticky-turbo-jest)

This is the first of many PR to improve the Developer QOL for testing and developing on metachain.

@fuxingloh fuxingloh changed the title refactor(packages): refactor(packages): move to a single root package.json with turbo pipelines Aug 30, 2022
@defichain-bot defichain-bot added the kind/refactor Non feature refactor change label Aug 30, 2022
@netlify
Copy link

netlify bot commented Aug 30, 2022

Deploy Preview for defimetachain ready!

Name Link
🔨 Latest commit 3ebb3cb
🔍 Latest deploy log https://app.netlify.com/sites/defimetachain/deploys/630e4fa754900800075d52fe
😎 Deploy Preview https://deploy-preview-42--defimetachain.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions
Copy link

github-actions bot commented Aug 30, 2022

Docker image for defich/metachain is ready!

Built with commit 648f810

  • docker pull ghcr.io/defich/metachain:648f81035f0c477d266c3096704c271b71849f6b
  • docker pull ghcr.io/defich/metachain:pr-42

@codecov
Copy link

codecov bot commented Aug 30, 2022

Codecov Report

Merging #42 (3ebb3cb) into main (11a4243) will not change coverage.
The diff coverage is n/a.

@@          Coverage Diff          @@
##            main     #42   +/-   ##
=====================================
  Coverage   3.79%   3.79%           
=====================================
  Files         10      10           
  Lines       1711    1711           
=====================================
  Hits          65      65           
  Misses      1646    1646           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@fuxingloh fuxingloh marked this pull request as ready for review August 30, 2022 19:38
@@ -1,10 +1,10 @@
{
"name": "@defichain/metachain-docs",
"name": "@defimetachain/docs",
"version": "0.0.0",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be higher than 0.0.0?
I am not really familiar with the software versioning used in cake. Do you have a link to the software versioning doc used in cake?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't have this documented yet, I'm working on the release model for this repo soon.

https://github.com/JellyfishSDK/jellyfish/blob/main/CONTRIBUTING.md#publishing

The TLDR is it will follow very closely to what was done at Jellyfish, where the release and the version are determined by the release drafter and annotated on release since we're doing trunk-based development.

It's related to this PR #47 where everything else is heavily automated, we just focus on pushing implementation and testing it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Copy link
Contributor

@DieHard073055 DieHard073055 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
Thanks :)

fuxingloh added a commit that referenced this pull request Sep 14, 2022
#### What this PR does / why we need it:

Refactor and move `ts-tests` into mono-repo style packages to allow
separation of context and downstream usability. This is the continuation
of #42

`@defimetachain/testcontainers`

Provides easy to use and test lightweight, throwaway instances of
MetaChain provisioned automatically in a Docker
container.

`MetaChainContainer` and `StartedMetaChainContainer` follows the
convention defined
in
[testcontainers/testcontainers-node](https://github.com/testcontainers/testcontainers-node)

```ts
let container: StartedMetaChainContainer;
let rpc: ethers.providers.JsonRpcProvider;

beforeEach(async () => {
  container = await new MetaChainContainer().start();
});

afterEach(async () => {
  await container.stop();
});

it('should createBlock', async function () {
  await container.createBlock();
  expect(await rpc.getBlockNumber()).toStrictEqual(1);
});
```


#### Which issue(s) does this PR fixes?:
<!--
(Optional) Automatically closes linked issue when PR is merged.
Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`.
-->
Fixes #78

#### Additional comments?:

The current implementation in `ts-tests` isn't yet migrated to use the
new standard and convention defined here. That should be done as part of
#79.
canonbrother pushed a commit that referenced this pull request Sep 28, 2022
#### What this PR does / why we need it:

Refactor and move `ts-tests` into mono-repo style packages to allow
separation of context and downstream usability. This is the continuation
of #42

`@defimetachain/testcontainers`

Provides easy to use and test lightweight, throwaway instances of
MetaChain provisioned automatically in a Docker
container.

`MetaChainContainer` and `StartedMetaChainContainer` follows the
convention defined
in
[testcontainers/testcontainers-node](https://github.com/testcontainers/testcontainers-node)

```ts
let container: StartedMetaChainContainer;
let rpc: ethers.providers.JsonRpcProvider;

beforeEach(async () => {
  container = await new MetaChainContainer().start();
});

afterEach(async () => {
  await container.stop();
});

it('should createBlock', async function () {
  await container.createBlock();
  expect(await rpc.getBlockNumber()).toStrictEqual(1);
});
```


#### Which issue(s) does this PR fixes?:
<!--
(Optional) Automatically closes linked issue when PR is merged.
Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`.
-->
Fixes #78

#### Additional comments?:

The current implementation in `ts-tests` isn't yet migrated to use the
new standard and convention defined here. That should be done as part of
#79.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants