Skip to content

Commit

Permalink
Merge pull request #3891 from coronasafe/develop
Browse files Browse the repository at this point in the history
Production Release; Oct Week 5
  • Loading branch information
mathew-alex authored Oct 30, 2022
2 parents c60fcbe + 0209786 commit b386abf
Show file tree
Hide file tree
Showing 103 changed files with 68,520 additions and 28,214 deletions.
20 changes: 19 additions & 1 deletion .github/workflows/cypress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,33 @@ jobs:
- name: Install dependencies 📦
run: npm install --legacy-peer-deps

- name: Compile rescript files ⚙️
run: "npm run re:build"

- name: Cypress run 🥬
uses: cypress-io/github-action@v4
with:
env: SKIP_PREFLIGHT_CHECK=true
install: false
start: npm run start
start: "npm run start:react"
wait-on: "http://localhost:4000"
wait-on-timeout: 300
browser: electron

- name: Remove cypress failed label on success 🏷️
uses: actions-ecosystem/action-remove-labels@v1
if: success()
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
labels: cypress failed

- name: Add cypress failed label on failure 🏷️
uses: actions-ecosystem/action-add-labels@v1
if: failure()
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
labels: cypress failed

- name: Upload cypress screenshots on failure 📸
uses: actions/upload-artifact@v2
if: failure()
Expand Down
32 changes: 32 additions & 0 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
const path = require("path");

module.exports = {
stories: ["../src/**/*.stories.mdx", "../src/**/*.stories.@(js|jsx|ts|tsx)"],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-interactions",
"storybook-dark-mode",
],
framework: "@storybook/react",
core: {
builder: "webpack5",
},
webpackFinal: (config) => {
config.module.rules.push({
test: /\.css$/,
use: [
{
loader: "postcss-loader",
options: {
postcssOptions: {
plugins: [require("tailwindcss"), require("autoprefixer")],
},
},
},
],
include: path.resolve(__dirname, "../"),
});
return config;
},
};
10 changes: 10 additions & 0 deletions .storybook/preview-head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<script
src="https://kit.fontawesome.com/d69454c2e7.js"
crossorigin="anonymous"
></script>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap"
rel="stylesheet"
/>
11 changes: 11 additions & 0 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import "../src/style/index.css";

export const parameters = {
actions: { argTypesRegex: "^on[A-Z].*" },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
};
2 changes: 1 addition & 1 deletion cypress/e2e/assets_spec/filter.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe("Assets Filter", () => {
});

it("Filter by Facility", () => {
cy.get("[placeholder='Search by facility name or by district']")
cy.get("[name=Facilities]")
.type("test")
.wait(3000)
.type("{downarrow}{enter}");
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/facility_spec/inventory.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ describe("Inventory Management Section", () => {
.should("contain", "Facility")
.contains("Facility")
.click({ force: true });
cy.contains("Inventory Management").click();
cy.contains("Manage Inventory").click();
});

it("Adds Inventory", () => {
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/facility_spec/locations.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ describe("Location Management Section", () => {
.should("contain", "Facility")
.contains("Facility")
.click({ force: true });
cy.contains("Location Management").click();
cy.contains("Manage Locations").click();
});

it("Adds Location", () => {
Expand Down
Loading

1 comment on commit b386abf

@vercel
Copy link

@vercel vercel bot commented on b386abf Oct 30, 2022

Choose a reason for hiding this comment

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

Successfully deployed to the following URLs:

care-storybook – ./

care-storybook-git-master-coronasafe.vercel.app
care-storybook-coronasafe.vercel.app

Please sign in to comment.