Skip to content

Commit

Permalink
update cypress
Browse files Browse the repository at this point in the history
  • Loading branch information
philschatz committed Dec 6, 2023
1 parent 44ecf4c commit f00f609
Show file tree
Hide file tree
Showing 9 changed files with 52 additions and 10 deletions.
43 changes: 43 additions & 0 deletions .gitpod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,49 @@
image:
file: .gitpod.Dockerfile

# Run these for the cypress tests:

# export CHROME_VERSION=119.0.6045.199-1
# export FIREFOX_VERSION=120.0

# # sudo apt-get update
# sudo apt-get install -y \
# libgtk2.0-0 \
# libgtk-3-0
# sudo DEBIAN_FRONTEND=noninteractive apt-get install -yq \
# libgbm-dev \
# libnotify-dev
# sudo apt-get install -y \
# libgconf-2-4 \
# libnss3 \
# libxss1
# sudo apt-get install -y \
# libasound2 \
# libxtst6 \
# xauth \
# libu2f-udev \
# xvfb

# sudo wget -O /usr/src/google-chrome-stable_current_amd64.deb "http://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb"
# sudo dpkg -i /usr/src/google-chrome-stable_current_amd64.deb

# sudo apt-get install -f -y && \
# sudo rm -f /usr/src/google-chrome-stable_current_amd64.deb

# google-chrome --version
# sudo apt-get install mplayer -y
# sudo wget --no-verbose -O /tmp/firefox.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/$FIREFOX_VERSION/linux-x86_64/en-US/firefox-$FIREFOX_VERSION.tar.bz2
# sudo tar -C /opt -xjf /tmp/firefox.tar.bz2 \
# && sudo rm /tmp/firefox.tar.bz2 \
# && sudo ln -fs /opt/firefox/firefox /usr/bin/firefox
# echo " node version: $(node -v) \n" \
# "npm version: $(npm -v) \n" \
# "yarn version: $(yarn -v) \n" \
# "debian version: $(cat /etc/debian_version) \n" \
# "Chrome version: $(google-chrome --version) \n" \
# "Firefox version: $(firefox --version) \n" \
# "git version: $(git --version) \n" \
# "whoami: $(whoami) \n"
tasks:
- init: npm install && npm run build:production
command: printf '\n\n 🎉🎉 The plugin is available in the Explorer 🎉🎉\n\nRight-click the .vsix file and click "Install Extension VSIX" to test it.\n\nRun "npm test" to run tests\n'
5 changes: 5 additions & 0 deletions cypress.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { defineConfig } from 'cypress'

export default defineConfig({
e2e: { baseUrl: null }
})
1 change: 0 additions & 1 deletion cypress.json

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
11 changes: 3 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
"lint": "eslint . --ext ts,js,jsx,tsx,json",
"lint:fix": "npm run lint -- --fix",
"pretest:cypress": "npm run build && ./scripts/pre-cypress.bash",
"test:cypress": "cypress run --quiet --config-file ./cypress.json",
"test:cypress": "npm run test:cypress:only",
"test:cypress:only": "cypress run --quiet --config-file ./cypress.config.ts",
"pretest:unit": "jest --clearCache",
"test:unit": "jest --coverage --coverageDirectory ./.nyc_output/",
"test:unit:watch": "npm run test:unit -- --watch --updateSnapshot",
Expand All @@ -41,13 +42,7 @@
},
"activationEvents": [
"onLanguage:xml",
"onCommand:openstax.showPreviewToSide",
"onCommand:openstax.showTocEditor",
"onCommand:openstax.showImageManager",
"onCommand:openstax.pushContent",
"onCommand:openstax.generateReadme",
"onView:tocTrees",
"onCommand:openstax.validateContent"
"onCommand:openstax.showImageManager"
],
"contributes": {
"commands": [
Expand Down
2 changes: 1 addition & 1 deletion snapshots.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
"__version": "9.4.1",
"__version": "13.6.0",
"toc-editor Webview Tests": {
"drag-n-drop": {
"allows dnd from uneditable to editable": {
Expand Down

0 comments on commit f00f609

Please sign in to comment.