Browse Source

test(acceptance): Remove percy (#20040)

Remove percy-related code/comments
Billy Vong 4 years ago
parent
commit
3936df2509

+ 1 - 1
.travis.yml

@@ -209,7 +209,7 @@ matrix:
 
     - <<: *acceptance_default
       name: 'Plugins'
-      env: TEST_SUITE=plugins DB=postgres PERCY_TOKEN=${PLUGIN_PERCY_TOKEN}
+      env: TEST_SUITE=plugins DB=postgres
 
     - python: 2.7
       name: 'Frontend [test]'

+ 0 - 6
Makefile

@@ -161,12 +161,6 @@ test-js-ci: node-version-check
 	@yarn run test-ci
 	@echo ""
 
-# builds and creates percy snapshots
-test-styleguide:
-	@echo "--> Building and snapshotting styleguide"
-	@yarn run snapshot
-	@echo ""
-
 test-python:
 	@echo "--> Running Python tests"
 	py.test tests/integration tests/sentry

+ 2 - 2
docs-ui/components/getDynamicText.stories.js

@@ -10,8 +10,8 @@ export default {
 export const GetDynamicText = withInfo(
   `
   Use this to wrap dynamic content (i.e. dates) for acceptance/snapshot tests.
-  Currently checks for existence of PERCY_TOKEN env var.
-  (storybook webpack config has webpack.DefinePlugin for "process.env.IS_PERCY")
+  Currently checks for IS_CI env var.
+  (webpack config has webpack.DefinePlugin for "process.env.IS_CI")
   `
 )(() => {
   return (

+ 0 - 1
package.json

@@ -193,7 +193,6 @@
     "dev-acceptance": "NO_DEV_SERVER=1 NODE_ENV=development yarn webpack --watch",
     "storybook": "SENTRY_UI_HOT_RELOAD='' start-storybook -p 9001 -c .storybook",
     "storybook-build": "build-storybook -c .storybook -o .storybook-out && sed -i -e 's/\\/sb_dll/sb_dll/g' .storybook-out/index.html",
-    "snapshot": "build-storybook && PERCY_TOKEN=$STORYBOOK_PERCY_TOKEN PERCY_PROJECT=$STORYBOOK_PERCY_PROJECT percy-storybook --widths=1280",
     "webpack-profile": "yarn -s webpack --profile --json > stats.json",
     "build": "yarn webpack --output-path=public"
   },

+ 0 - 1
requirements-base.txt

@@ -84,5 +84,4 @@ phabricator>=0.6.0,<1.0
 
 # test dependencies, but unable to move to requirements-test until sentry.utils.pytest and similar are moved to tests/
 mock==3.0.5 ; python_version < "3.3"
-percy>=1.1.2
 selenium==3.141.0

+ 0 - 4
src/sentry/conf/server.py

@@ -786,10 +786,6 @@ REST_FRAMEWORK = {
 
 CRISPY_TEMPLATE_PACK = "bootstrap3"
 
-# Percy config for visual regression testing.
-
-PERCY_DEFAULT_TESTING_WIDTHS = (1280, 375)
-
 # Sentry and internal client configuration
 
 SENTRY_FEATURES = {

+ 0 - 1
src/sentry/static/sentry/app/bootstrap.tsx

@@ -4,7 +4,6 @@ import 'bootstrap/js/dropdown';
 import 'focus-visible';
 
 import 'app/utils/statics-setup';
-import 'app/utils/emotion-setup';
 
 import PropTypes from 'prop-types';
 import React from 'react';

+ 0 - 1
src/sentry/static/sentry/app/constants/index.tsx

@@ -252,7 +252,6 @@ export const DISCOVER2_DOCS_URL =
   'https://docs.sentry.io/performance-monitoring/discover-queries/';
 
 export const IS_CI = !!process.env.IS_CI;
-export const IS_PERCY = !!process.env.IS_PERCY;
 export const NODE_ENV = process.env.NODE_ENV;
 export const DISABLE_RR_WEB = !!process.env.DISABLE_RR_WEB;
 export const SPA_DSN = process.env.SPA_DSN;

+ 1 - 1
src/sentry/static/sentry/app/data/forms/apiApplication.tsx

@@ -15,7 +15,7 @@ const forms: JsonFormObject[] = [
         // additional data/props that is related to rendering of form field rather than data
         label: 'Name',
         help: 'e.g. My Application',
-        setValue: value => getDynamicText({value, fixed: 'PERCY_APPLICATION_NAME'}),
+        setValue: value => getDynamicText({value, fixed: 'CI_APPLICATION_NAME'}),
       },
       {
         name: 'homepageUrl',

+ 0 - 10
src/sentry/static/sentry/app/utils/emotion-setup.tsx

@@ -1,10 +0,0 @@
-// NEEDS to be true for production because of performance
-// But travis builds with NODE_ENV = production, so turn off speed when
-
-import {IS_PERCY} from 'app/constants';
-
-// IS_PERCY is true (i.e. we are in TRAVIS and PERCY_TOKEN is set)
-if (IS_PERCY) {
-  const sheet = require('emotion').sheet; // eslint-disable-line emotion/no-vanilla
-  sheet.speedy(false);
-}

Some files were not shown because too many files changed in this diff