DevExpress / testcafe

A Node.js tool to automate end-to-end web testing.
https://testcafe.io
MIT License
9.83k stars 674 forks source link

.maximizeWindow() stopped working with testcafe 1.20.1 #7696

Closed pgusilic-devops closed 1 year ago

pgusilic-devops commented 1 year ago

What is your Scenario?

After recent upgrade to the latest version TestCafe it started to throw an exception when trying to maximizeWindow. testcafe 1.20.1

MacBook Pro, Intel Core I5 MacOS Ventura 13.3.1

What is the Current behavior?

Getting an exception

Warnings (1):

Was unable to maximize the window due to an error.

The get-window-max-bounds process failed with the 1 exit code. Process output: Incorrect arguments

Exit code: 1

What is the Expected behavior?

The window should be maximized.

What is your public website URL? (or attach your complete example)

I've tried it even with a simple test on Google.com

What is your TestCafe test code?

import { TestType } from "../../consts";

fixture("Case Discovery") .beforeEach(async (t: TestController) => { await t.maximizeWindow() await t.wait(1000); }); fixture('Login page').page('google.com'); test.only.meta({ CID: 'C15', type: TestType.Critical })( 'Successful Login', async (t) => { // When await t .maximizeWindow() .click('input[value="Google Search"]') })

Your complete configuration file

testconfig.json { "compilerOptions": { "esModuleInterop": true, "resolveJsonModule": true, "allowSyntheticDefaultImports": true, "baseUrl": "./app/", "downlevelIteration": true, "experimentalDecorators": true, "jsx": "react", // To remove this setting, we have to remove/upgrade AntD and ImmutableJS "keyofStringsOnly": true, "lib": ["dom", "esnext"], "module": "commonjs", "moduleResolution": "node", "noImplicitAny": true, "noUnusedLocals": true, "outDir": "./lib", "preserveConstEnums": true, "removeComments": false, "skipLibCheck": true, "sourceMap": true, "suppressImplicitAnyIndexErrors": true, "target": "es5" },

}

Your complete test report

Warnings (1):

Was unable to maximize the window due to an error.

The get-window-max-bounds process failed with the 1 exit code. Process output: Incorrect arguments

Exit code: 1

Screenshots

image

Steps to Reproduce

Just create a code with the maximizeWindow

TestCafe version

Using locally installed version of TestCafe. 1.20.1

Node.js version

v14.16.0

Command-line arguments

npm run test:debug

Browser name(s) and version(s)

Version 112.0.5615.137 (Official Build) (x86_64)

Platform(s) and version(s)

MacOS Ventura 13.3.1

Other

Not really sure what else i could provide. It just not resizing the screen.

Aleksey28 commented 1 year ago

Hi @pgusilic-devops ,

An issue with the same problem has already been created. Let's continue our discussion there: #7684.

This issue will be closed.