Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
83 commits
Select commit Hold shift + click to select a range
7ab77be
Update config.yml
schurchleycci Apr 10, 2023
fe04cb2
Update cartItemCard.spec.ts
schurchleycci Apr 10, 2023
68d61f7
Update cartItemCard.spec.ts
schurchleycci Apr 10, 2023
e7cbf87
Update cartItemCard.spec.ts
schurchleycci Apr 10, 2023
7768106
Update config.yml
schurchleycci Apr 10, 2023
e0fd9bb
Update config.yml
schurchleycci Apr 10, 2023
ce8ae81
Updated config.yml
schurchleycci Apr 10, 2023
4cc587a
Update cartItemCard.spec.ts
schurchleycci Apr 11, 2023
1b1c353
Update cartItemCard.spec.ts
schurchleycci Apr 11, 2023
66de945
Update config.yml
schurchleycci Apr 11, 2023
27e167b
Update config.yml
schurchleycci Apr 11, 2023
ce9c70a
Update config.yml
schurchleycci Apr 11, 2023
45556e2
Update config.yml
schurchleycci Apr 11, 2023
7c301dd
Update config.yml
schurchleycci Apr 11, 2023
a15fce6
Update config.yml
schurchleycci Apr 11, 2023
2ccf0b4
Update config.yml
schurchleycci Apr 11, 2023
e54fa79
Update config.yml
schurchleycci Apr 11, 2023
e5bf7de
Update config.yml
schurchleycci Apr 11, 2023
f9a4644
Update config.yml
schurchleycci Apr 11, 2023
da72cb2
Update config.yml
schurchleycci Apr 11, 2023
8177c0a
Update config.yml
schurchleycci Apr 11, 2023
d6f621c
Update config.yml
schurchleycci Apr 11, 2023
40b5c36
Update config.yml
schurchleycci Apr 11, 2023
c04e6ef
Update config.yml
schurchleycci Apr 11, 2023
3106a05
Update menuCard.spec.ts
schurchleycci Apr 11, 2023
87f266e
Update config.yml
schurchleycci Apr 11, 2023
8ff397f
Update config.yml
schurchleycci Apr 11, 2023
6b21f70
Update config.yml
schurchleycci Apr 11, 2023
50f6f1b
Update package.json
schurchleycci Apr 11, 2023
cabfcaa
Update config.yml
schurchleycci Apr 11, 2023
338c10d
Update package.json
schurchleycci Apr 11, 2023
10f07c8
Update config.yml
schurchleycci Apr 11, 2023
5e03126
Update package.json
schurchleycci Apr 11, 2023
3ec6429
Update cartItemCard.spec.ts
schurchleycci Apr 11, 2023
fb40df3
Update config.yml
schurchleycci Apr 11, 2023
c7a0bb3
Update config.yml
schurchleycci Apr 11, 2023
3510c17
Update CartItemCard.vue
schurchleycci Apr 11, 2023
7082b03
Update CartItemCard.vue
schurchleycci Apr 11, 2023
0cddef2
Update CartItemCard.vue
schurchleycci Apr 11, 2023
065cd26
Update CartItemCard.vue
schurchleycci Apr 11, 2023
352f33f
Update config.yml
schurchleycci Apr 11, 2023
c248350
Update config.yml
schurchleycci Apr 11, 2023
0ed2156
Update config.yml
schurchleycci Apr 11, 2023
39ff625
Update config.yml
schurchleycci Apr 11, 2023
1996cd9
update config
schurchleycci Apr 11, 2023
5f3f3cf
update config
schurchleycci Apr 11, 2023
afa39b5
try new cypress reporter
schurchleycci Apr 14, 2023
befb49e
fix config
schurchleycci Apr 14, 2023
5d9d15d
update Orb
schurchleycci Apr 14, 2023
fc86781
fix config
schurchleycci Apr 14, 2023
ebdbe81
try direct cypress job
schurchleycci Apr 14, 2023
c6efd61
fix config
schurchleycci Apr 14, 2023
c0f3c98
add executor
schurchleycci Apr 14, 2023
11f9a1e
add checkout
schurchleycci Apr 14, 2023
2a39fa6
add install
schurchleycci Apr 14, 2023
1dcc723
actually install this time
schurchleycci Apr 14, 2023
86013a1
missed a -
schurchleycci Apr 14, 2023
7a3efce
try install cypress
schurchleycci Apr 14, 2023
ace1cd9
test
schurchleycci Apr 14, 2023
27b36ab
new image
schurchleycci Apr 14, 2023
3dc9a38
try plugin
schurchleycci Apr 14, 2023
6b67e9e
fix indent
schurchleycci Apr 14, 2023
d81f1ca
add xargs
schurchleycci Apr 14, 2023
1dd8513
fix =
schurchleycci Apr 14, 2023
53bf8ff
browsers image
schurchleycci Apr 14, 2023
dcc00ab
yarn test script
schurchleycci Apr 14, 2023
238c98a
try splitting
schurchleycci Apr 14, 2023
dcf60df
with parallelism
schurchleycci Apr 14, 2023
86c9a4c
update config
schurchleycci Apr 14, 2023
4f521cc
Updated config.yml
schurchleycci Apr 19, 2023
c704555
Updated config.yml
schurchleycci Apr 19, 2023
ecadc59
Updated config.yml
schurchleycci Apr 19, 2023
57fcbb0
Updated config.yml
schurchleycci Apr 19, 2023
39479a3
Updated config.yml
schurchleycci Apr 19, 2023
968e705
Updated config.yml
schurchleycci Apr 19, 2023
3b557e3
Updated config.yml
schurchleycci May 8, 2023
cf40bc6
Updated config.yml
schurchleycci May 8, 2023
ad7167d
Update config.yml
schurchleycci May 8, 2023
7b648fa
Updated config.yml
schurchleycci May 8, 2023
447adbd
Updated config.yml
schurchleycci May 8, 2023
a9fba2c
Updated config.yml
schurchleycci May 8, 2023
d362d7a
Updated config.yml
schurchleycci May 8, 2023
8464152
Updated config.yml
schurchleycci May 8, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 43 additions & 23 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ orbs:
# Orbs reduce the amount of configuration required for common tasks.
# See the orb documentation here: https://circleci.com/developer/orbs/orb/circleci/node
node: circleci/node@5
cypress: cypress-io/cypress@2.1.0
cypress: cypress-io/cypress@3.1.1

jobs:
# Below is the definition of your job to test your Node app. You can rename and customize it as you want.
Expand All @@ -21,28 +21,48 @@ jobs:
# You can specify an image from Dockerhub or use one of our Convenience Images from CircleCI's Developer Hub.
# A list of available CircleCI docker Convenience Images are available here: https://circleci.com/developer/images/image/cimg/node
docker:
- image: cimg/node:16.16
- image: cimg/node:19.9.0
# Then run your tests!
# CircleCI will report the results back to your VCS provider.
steps:
# Checkout the code as the first step.
- checkout
# Next, the node orb's install-packages step will install the dependencies from a package.json.
# The orb install-packages step will also automatically cache them for faster future runs.
- node/install-packages:
pkg-manager: "yarn"
- when:
condition: << pipeline.git.base_revision >>
steps:
- run:
name: Run tests
command: yarn run test:unit --changedSince << pipeline.git.base_revision >>
- unless:
condition: << pipeline.git.base_revision >>
steps:
- run:
name: Run tests
command: yarn run test:unit
override-ci-command: "yarn install"
- run:
name: Run tests
command: |
touch ./tests/unit/french.spec.ts
echo "import { mount } from \"@vue/test-utils\";import CartItemCard from \"@/components/CartItemCard.vue\";describe(\"CartItemCard.vue\", () => {it(\"renders the menuItem prop data\", () => {const menuItem = {id: 1, name: \"French Fries\", description: \"Fried potato rectangles\", price: \"2.99\", imageId: \"1\",};const wrapper = mount(CartItemCard, {props: { menuItem },} as any);expect(wrapper.text()).toContain(\"French\");});});" > ./tests/unit/french.spec.ts
cat ./tests/unit/french.spec.ts
git bisect start
git bisect bad 065cd263aca7c9573206d21366141fe56a3a1773
git bisect good 3106a0587a16f7c62db7edf1501365abe1a774c3
git bisect run yarn test:unit french.spec.ts

run_cypress_tests:
parallelism: 3
docker:
- image: cimg/node:16.19.1-browsers
steps:
- checkout
- run:
name: Install deps
command: |
yarn install
mkdir test_results
- run:
name: Install the reporter
command: yarn add cypress-circleci-reporter mocha --dev
- run:
name: Run cypress tests
command: |
circleci tests glob "cypress/**/*.cy.js" | circleci tests run --command="xargs npx cypress run --reporter cypress-circleci-reporter --spec" --verbose
- store_test_results:
path: test_results
- store_artifacts:
path: test_results

workflows:
# Below is the definition of your workflow.
Expand All @@ -51,10 +71,10 @@ workflows:
# For more details on extending your workflow, see the configuration docs: https://circleci.com/docs/2.0/configuration-reference/#workflows
sample:
jobs:
- test
- cypress/run:
executor: "node-cypress"
command: yarn run test:e2e --headless
yarn: true
# For running simple node tests, you could optionally instead use the node/test job from the orb to replicate and replace the manually defined "test" job above in fewer lines.
# - node/test
# - test
- run_cypress_tests
- hold:
type: approval
- test:
requires:
- hold
8 changes: 8 additions & 0 deletions cypress/e2e/test2.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// https://docs.cypress.io/api/table-of-contents

describe("My First Test", () => {
it("Visits the app root url", () => {
cy.visit("/");
cy.contains("ion-title", "Continuous Food Delivery");
});
});
8 changes: 8 additions & 0 deletions cypress/e2e/test3.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// https://docs.cypress.io/api/table-of-contents

describe("My First Test", () => {
it("Visits the app root url", () => {
cy.visit("/");
cy.contains("ion-title", "Continuous Food Delivery");
});
});
3 changes: 1 addition & 2 deletions src/components/CartItemCard.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<template>
<ion-card class="cartCard" @click="deleteCartItem(menuItem)">
<img :src="imageUrl" class="cartImage"/>
<div class="cartCardNameContainer"> {{ menuItem.name }} </div>
<div>{{ menuItem.price }}</div>
<div><ion-button><ion-icon :icon="trashOutline"></ion-icon></ion-button></div>
</ion-card>
Expand All @@ -11,7 +10,7 @@
.cartCard {
display: flex;
flex-direction: row;
height: 100px;
height: 200px;
}

.cartCard div {
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/menuCard.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ describe("CartItemCard.vue", () => {
imageId: "1",
};
const wrapper = mount(MenuItemCard, {
props: { menuItem },
props: { menuItem }
} as any);

expect(wrapper.find("ion-card-title").text()).toEqual("French Fries");
Expand Down