Skip to content

Commit

Permalink
Replace Rome with Biome (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
KaiSpencer authored Dec 31, 2023
1 parent 979ba6c commit b99f5a8
Show file tree
Hide file tree
Showing 85 changed files with 1,834 additions and 1,745 deletions.
18 changes: 9 additions & 9 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": ["cypress-testing"]
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": ["cypress-testing"]
}
20 changes: 18 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
{
"typescript.tsdk": "node_modules/typescript/lib"
}
"typescript.tsdk": "node_modules/typescript/lib",
"editor.defaultFormatter": "biomejs.biome",

"editor.formatOnSave": true,
"prettier.enable": false,
"[typescriptreact]": {
"editor.defaultFormatter": "biomejs.biome"
},
"[typescript]": {
"editor.defaultFormatter": "biomejs.biome"
},
"[javascript]": {
"editor.defaultFormatter": "biomejs.biome"
},
"[json]": {
"editor.defaultFormatter": "biomejs.biome"
}
}
36 changes: 18 additions & 18 deletions apps/cypress-testing/cypress.config.ts
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
import { defineConfig } from "cypress";
export default defineConfig({
video: false,
component: {
viewportWidth: 1000,
viewportHeight: 500,
devServer: {
framework: "react",
bundler: "vite",
viteConfig: {
server: { fs: { strict: false } },
resolve:{
alias:{
'@' : "../../node_modules/react-trello-ts/src"
},
},
},
},
},
experimentalSourceRewriting: true,
video: false,
component: {
viewportWidth: 1000,
viewportHeight: 500,
devServer: {
framework: "react",
bundler: "vite",
viteConfig: {
server: { fs: { strict: false } },
resolve: {
alias: {
"@": "../../node_modules/react-trello-ts/src",
},
},
},
},
},
experimentalSourceRewriting: true,
});
128 changes: 64 additions & 64 deletions apps/cypress-testing/cypress/component/CardBehaviour.cy.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,72 +57,72 @@ describe("Testing card behaviour", () => {
});

it("Can drag a card between lanes", () => {
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.findCardByTitle("Buy milk").move({
deltaX: 300,
deltaY: 50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("exist");
});
});
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.findCardByTitle("Buy milk").move({
deltaX: 300,
deltaY: 50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("exist");
});
});

it("Can drag a card between multiple lanes", () => {
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.findCardByTitle("Buy milk").move({
deltaX: 300,
deltaY: 50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("exist");
it("Can drag a card between multiple lanes", () => {
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.findCardByTitle("Buy milk").move({
deltaX: 300,
deltaY: 50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("exist");

cy.findCardByTitle("Buy milk").move({
deltaX: -300,
deltaY: -50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("not.exist");
cy.findCardByTitle("Buy milk").move({
deltaX: -300,
deltaY: -50,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("exist");
cy.get(".horizontal > :nth-child(2)")
.findByText("Buy milk")
.should("not.exist");

cy.findCardByTitle("Buy milk").move({
deltaX: 550,
deltaY: -100,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(3)")
.findByText("Buy milk")
.should("exist");
cy.findCardByTitle("Buy milk").move({
deltaX: 550,
deltaY: -100,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("not.exist");
cy.get(".horizontal > :nth-child(3)")
.findByText("Buy milk")
.should("exist");

cy.findCardByTitle("Buy milk").move({
deltaX: -550,
deltaY: 100,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("exist");
cy.get(".horizontal > :nth-child(3)")
.findByText("Buy milk")
.should("not.exist");
});
})
cy.findCardByTitle("Buy milk").move({
deltaX: -550,
deltaY: 100,
force: true,
});
cy.get(".horizontal > :nth-child(1)")
.findByText("Buy milk")
.should("exist");
cy.get(".horizontal > :nth-child(3)")
.findByText("Buy milk")
.should("not.exist");
});
});
});
43 changes: 20 additions & 23 deletions apps/cypress-testing/cypress/component/ComponentName.cy.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,26 @@
import Board from "react-trello-ts";

describe("ComponentName.cy.ts", () => {
it("renders cards", () => {
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.get(".horizontal")
.findAllByText("Planned Tasks")
.should("exist")
.should("have.length", 1);
cy.findCardByTitle("Buy milk");
cy.findCardByTitle("Dispose Garbage");
cy.findCardByTitle("Write Blog");
cy.findCardByTitle("Pay Rent");
cy.findCardByTitle("Clean House");
cy.findCardByTitle("Practice Meditation");
cy.findCardByTitle("Maintain Daily Journal");
cy.findCardByTitle("Morning Jog");
cy.findCardByTitle("Go Trekking");
cy.findCardByTitle("Go Jogging");
cy.findCardByTitle("Go Cycling");
});
});



it("renders cards", () => {
cy.fixture("data.json").then((data) => {
cy.mount(<Board data={data} />);
cy.get(".horizontal")
.findAllByText("Planned Tasks")
.should("exist")
.should("have.length", 1);
cy.findCardByTitle("Buy milk");
cy.findCardByTitle("Dispose Garbage");
cy.findCardByTitle("Write Blog");
cy.findCardByTitle("Pay Rent");
cy.findCardByTitle("Clean House");
cy.findCardByTitle("Practice Meditation");
cy.findCardByTitle("Maintain Daily Journal");
cy.findCardByTitle("Morning Jog");
cy.findCardByTitle("Go Trekking");
cy.findCardByTitle("Go Jogging");
cy.findCardByTitle("Go Cycling");
});
});
});

export {};
Loading

1 comment on commit b99f5a8

@vercel
Copy link

@vercel vercel bot commented on b99f5a8 Jan 1, 2024

Choose a reason for hiding this comment

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

Please sign in to comment.