diff --git a/gulp/constants/functional-test-globs.js b/gulp/constants/functional-test-globs.js index 9f047c91c7b..e77cadc9abd 100644 --- a/gulp/constants/functional-test-globs.js +++ b/gulp/constants/functional-test-globs.js @@ -28,35 +28,16 @@ const DEBUG_GLOB_2 = [ ]; const PROXYLESS_TESTS_GLOB = [ - ...SCREENSHOT_TESTS_GLOB, - 'test/functional/fixtures/app-command/test.js', - 'test/functional/fixtures/driver/test.js', - 'test/functional/fixtures/page-error/test.js', - 'test/functional/fixtures/page-js-errors/test.js', - 'test/functional/fixtures/api/es-next/disable-reloads/test.js', - 'test/functional/fixtures/quarantine/test.js', - 'test/functional/fixtures/api/es-next/cookies/test.js', - 'test/functional/fixtures/concurrency/test.js', - 'test/functional/fixtures/api/es-next/request-hooks/test.js', - 'test/functional/fixtures/api/es-next/iframe-switching/test.js', - 'test/functional/fixtures/api/es-next/console/test.js', - 'test/functional/fixtures/api/es-next/roles/test.js', - 'test/functional/fixtures/request-pipeline/**/test.js', - 'test/functional/fixtures/hammerhead/worker/test.js', - 'test/functional/fixtures/api/es-next/native-dialogs-handling/test.js', - 'test/functional/fixtures/api/es-next/native-dialogs-handling/iframe/test.js', - 'test/functional/fixtures/page-js-errors/test.js', - 'test/functional/fixtures/api/es-next/click/test.js', - 'test/functional/fixtures/api/es-next/assertions/test.js', - 'test/functional/fixtures/api/es-next/browser-info/test.js', - 'test/functional/fixtures/api/es-next/client-function/test.js', - 'test/functional/fixtures/api/es-next/compiler-options/test.js', - 'test/functional/fixtures/api/es-next/execution-timeout/test.js', - 'test/functional/fixtures/api/es-next/generic-errors/test.js', - 'test/functional/fixtures/api/es-next/global-hooks/test.js', - 'test/functional/fixtures/api/es-next/hooks/test.js', - 'test/functional/fixtures/api/es-next/auth/test.js', - 'test/functional/fixtures/regression/**/test.js', + ...TESTS_GLOB, + '!test/functional/fixtures/ui/test.js', + '!test/functional/fixtures/browser-provider/browser-reconnect/test.js', + '!test/functional/fixtures/browser-provider/job-reporting/test.js', + '!test/functional/fixtures/driver/script-execution-barrier/test.js', + '!test/functional/fixtures/run-options/request-timeout/test.js', + '!test/functional/fixtures/run-options/disable-page-caching/test.js', + '!test/functional/fixtures/live/test.js', + '!test/functional/fixtures/api/es-next/navigate-to-and-test-page/test.js', + '!test/functional/fixtures/api/es-next/request/test.js', '!test/functional/fixtures/regression/gh-1138/test.js', '!test/functional/fixtures/regression/gh-1311/test.js', '!test/functional/fixtures/regression/gh-1388/test.js', @@ -64,6 +45,7 @@ const PROXYLESS_TESTS_GLOB = [ '!test/functional/fixtures/regression/gh-1846/test.js', '!test/functional/fixtures/regression/gh-2546/test.js', '!test/functional/fixtures/regression/gh-2601/test.js', + '!test/functional/fixtures/hammerhead/gh-2622/test.js', '!test/functional/fixtures/regression/gh-2861/test.js', '!test/functional/fixtures/regression/gh-3127/test.js', '!test/functional/fixtures/regression/gh-423/test.js', @@ -71,7 +53,6 @@ const PROXYLESS_TESTS_GLOB = [ '!test/functional/fixtures/regression/gh-5886/test.js', '!test/functional/fixtures/regression/gh-664/test.js', '!test/functional/fixtures/regression/hammerhead/gh-2350/test.js', - 'test/functional/fixtures/api/es-next/custom-client-scripts/test.js', ]; module.exports = { diff --git a/test/functional/fixtures/api/es-next/drag/test.js b/test/functional/fixtures/api/es-next/drag/test.js index 75cf2a1737c..7ec5b5f9c87 100644 --- a/test/functional/fixtures/api/es-next/drag/test.js +++ b/test/functional/fixtures/api/es-next/drag/test.js @@ -1,4 +1,5 @@ -const expect = require('chai').expect; +const { skipInProxyless } = require('../../../../utils/skip-in'); +const { expect } = require('chai'); describe('[API] Drag actions', function () { @@ -136,7 +137,7 @@ describe('[API] Drag actions', function () { return runTests('./testcafe-fixtures/drag-and-drop-test.js', 'try to drop to undroppable', { skip: ['iphone', 'ipad', 'android'] }); }); - it('Should reproduce native browser behavior', function () { + skipInProxyless('Should reproduce native browser behavior', function () { return runTests('./testcafe-fixtures/drag-and-drop-test.js', 'drag link and image', { only: ['chrome'] }); }); diff --git a/test/functional/fixtures/api/es-next/navigate-to-and-test-page/test.js b/test/functional/fixtures/api/es-next/navigate-to-and-test-page/test.js index 170a1d4d1ae..4608a074f02 100644 --- a/test/functional/fixtures/api/es-next/navigate-to-and-test-page/test.js +++ b/test/functional/fixtures/api/es-next/navigate-to-and-test-page/test.js @@ -1,4 +1,4 @@ -const expect = require('chai').expect; +const { expect } = require('chai'); describe('[API] t.navigateTo', function () { it('Should validate the url argument', function () { diff --git a/test/functional/fixtures/api/es-next/scroll/test.js b/test/functional/fixtures/api/es-next/scroll/test.js index f6ee8468cf5..47d0959b40c 100644 --- a/test/functional/fixtures/api/es-next/scroll/test.js +++ b/test/functional/fixtures/api/es-next/scroll/test.js @@ -1,4 +1,6 @@ -describe('Scroll', () => { +const { skipDescribeInProxyless } = require('../../../../utils/skip-in'); + +skipDescribeInProxyless('Scroll', () => { it('Should raise events for scroll', () => { return runTests('./testcafe-fixtures/raise-events.js'); }); diff --git a/test/functional/fixtures/api/es-next/upload/test.js b/test/functional/fixtures/api/es-next/upload/test.js index b1e87ce6b8b..562e0e51349 100644 --- a/test/functional/fixtures/api/es-next/upload/test.js +++ b/test/functional/fixtures/api/es-next/upload/test.js @@ -1,9 +1,10 @@ -const { expect } = require('chai'); -const path = require('path'); +const { expect } = require('chai'); +const path = require('path'); +const { skipInProxyless } = require('../../../../utils/skip-in'); describe('[API] Upload', function () { describe('t.setFilesToUpload', function () { - it('Should upload the specified file', function () { + skipInProxyless('Should upload the specified file', function () { return runTests('./testcafe-fixtures/upload-test.js', 'Upload the file', { only: 'chrome' }); }); diff --git a/test/functional/fixtures/api/json/test.js b/test/functional/fixtures/api/json/test.js index 66b7c1f2354..007a36ca580 100644 --- a/test/functional/fixtures/api/json/test.js +++ b/test/functional/fixtures/api/json/test.js @@ -1,12 +1,13 @@ -const { expect } = require('chai'); -const path = require('path'); +const { expect } = require('chai'); +const path = require('path'); +const { skipInProxyless } = require('../../../utils/skip-in'); describe('[API] DevTools Compiler', function () { it('Should make click on a button', function () { return runTests('./testcafe-fixtures/click-test.json', null, { only: 'chrome' }); }); - it('Should make hover on a button', function () { + skipInProxyless('Should make hover on a button', function () { return runTests('./testcafe-fixtures/hover-test.json', null, { only: 'chrome' }); }); @@ -57,7 +58,7 @@ describe('[API] DevTools Compiler', function () { return runTests('./testcafe-fixtures/wait-for-element-test.json', null, { only: 'chrome' }); }); - it('Should switch to iframe', function () { + skipInProxyless('Should switch to iframe', function () { return runTests('./testcafe-fixtures/iframe-test.json', null, { only: 'chrome' }); }); @@ -79,7 +80,7 @@ describe('[API] DevTools Compiler', function () { }); }); - it('Should click inside shadow DOM', function () { + skipInProxyless('Should click inside shadow DOM', function () { return runTests('./testcafe-fixtures/shadow-dom-test.json', null, { only: 'chrome', shouldFail: true, diff --git a/test/functional/fixtures/api/raw/upload/test.js b/test/functional/fixtures/api/raw/upload/test.js index 9a72a8aefb6..1e8b0e1f9cc 100644 --- a/test/functional/fixtures/api/raw/upload/test.js +++ b/test/functional/fixtures/api/raw/upload/test.js @@ -1,9 +1,10 @@ -const expect = require('chai').expect; -const errorInEachBrowserContains = require('../../../../assertion-helper.js').errorInEachBrowserContains; +const { skipInProxyless } = require('../../../../utils/skip-in'); +const { expect } = require('chai'); +const { errorInEachBrowserContains } = require('../../../../assertion-helper.js'); describe('[Raw API] Upload', function () { - it('Should upload a file', function () { + skipInProxyless('Should upload a file', function () { return runTests('./testcafe-fixtures/upload.testcafe', 'Upload a file', { shouldFail: true }) .catch(function (errs) { errorInEachBrowserContains(errs, 'File uploaded', 0); @@ -25,7 +26,7 @@ describe('[Raw API] Upload', function () { }); }); - it('Should upload files', function () { + skipInProxyless('Should upload files', function () { return runTests('./testcafe-fixtures/upload.testcafe', 'Upload files', { shouldFail: true }) .catch(function (errs) { errorInEachBrowserContains(errs, 'Files uploaded', 0); diff --git a/test/functional/fixtures/proxy/test.js b/test/functional/fixtures/proxy/test.js index 4bd7d6ed380..36281da9841 100644 --- a/test/functional/fixtures/proxy/test.js +++ b/test/functional/fixtures/proxy/test.js @@ -1,5 +1,6 @@ -const os = require('os'); -const expect = require('chai').expect; +const os = require('os'); +const { expect } = require('chai'); +const { skipInProxyless } = require('../../utils/skip-in'); const TRUSTED_PROXY_URL = os.hostname() + ':3004'; const TRANSPARENT_PROXY_URL = os.hostname() + ':3005'; @@ -10,7 +11,7 @@ describe('Using external proxy server', function () { return runTests('testcafe-fixtures/index.test.js', null, { useProxy: TRANSPARENT_PROXY_URL }); }); - it('Should open restricted page via trusted proxy server', function () { + skipInProxyless('Should open restricted page via trusted proxy server', function () { return runTests('testcafe-fixtures/restricted-page.test.js', null, { useProxy: TRUSTED_PROXY_URL }); }); }); @@ -39,7 +40,7 @@ describe('Using proxy-bypass', function () { }); }); - it('Should open page without proxy but get resource with proxy', function () { + skipInProxyless('Should open page without proxy but get resource with proxy', function () { const http = require('http'); const server = http.createServer(function (req, res) { diff --git a/test/functional/fixtures/reporter/test.js b/test/functional/fixtures/reporter/test.js index bb5a240c51c..0acd462229e 100644 --- a/test/functional/fixtures/reporter/test.js +++ b/test/functional/fixtures/reporter/test.js @@ -1,4 +1,4 @@ -const expect = require('chai').expect; +const { expect } = require('chai'); const fs = require('fs'); const generateReporter = require('./reporter'); const { createReporter } = require('../../utils/reporter'); @@ -7,6 +7,7 @@ const ReporterPluginMethod = require('../../../../lib/reporter/plugin-metho const assertionHelper = require('../../assertion-helper.js'); const path = require('path'); const config = require('../../config'); +const { skipInProxyless } = require('../../utils/skip-in'); const { createSimpleTestStream, @@ -945,7 +946,7 @@ const experimentalDebug = !!process.env.EXPERIMENTAL_DEBUG; }); } - it('Should get warning for request hook', async () => { + skipInProxyless('Should get warning for request hook', async () => { await runTests('./testcafe-fixtures/failed-cors-validation.js', 'Failed CORS validation', { only: 'chrome', reporter, @@ -1162,7 +1163,7 @@ const experimentalDebug = !!process.env.EXPERIMENTAL_DEBUG; }); }); - it('Should raise an error when uncaught exception occurred in any reporter method', async () => { + skipInProxyless('Should raise an error when uncaught exception occurred in any reporter method', async () => { function createReporterWithBrokenMethod (method) { const base = { async reportTaskStart () {}, @@ -1211,7 +1212,7 @@ const experimentalDebug = !!process.env.EXPERIMENTAL_DEBUG; }); }); - it('Should set options _hasTaskErrors to the runner if an error occurs', async () => { + skipInProxyless('Should set options _hasTaskErrors to the runner if an error occurs', async () => { try { await runTests('testcafe-fixtures/index-test.js', 'Simple command err test', { only: ['chrome'], shouldFail: true }); }