DevExpress / testcafe

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

Firefox m.parseProxyUrl(...) is null #2281

Closed dweber019 closed 6 years ago

dweber019 commented 6 years ago

Are you requesting a feature or reporting a bug?

Bug

What is the current behavior?

Get error in firefox

✖ Should have search results for "SBB"

   1) Error on page "https://openwt.com":

      TypeError: m.parseProxyUrl(...) is null

      Browser: Firefox 59.0.0 / Mac OS X 10.13.0

         40 |
         41 |  const searchIcon = owtHomePageModel.searchIcon;
         42 |  const searchInput = owtHomePageModel.searchInput;
         43 |
         44 |  await t
       > 45 |    .click(searchIcon)
         46 |    .typeText(searchInput, 'SBB')
         47 |    .pressKey('enter');
         48 |
         49 |  const searchResultsFirstTitle = owtHomePageModel.searchResultItems.find('.title').nth(0);
         50 |

What is the expected behavior?

No error... Btw. it runs successful in chrome, safari...

How would you reproduce the current behavior (if this is a bug)?

Run the code below ;)

Provide the test code and the tested page URL (if applicable)

Tested page URL: process.env.HOST=https://openwt.com

Test code

import { Selector } from 'testcafe';

export default class OwtHomePageModel {
    constructor(
        public aiBanner = Selector('#block-artificialintelligencebanner').find('.title1'),
        public services = Selector('#block-services').find('.service'),
        public searchIcon = Selector('.search-container').find('.fa-search'),
        public searchInput = Selector('.search-container').find('#edit-search-block-form'),
        public searchResultItems = Selector('.search-results').find('.search-result'),
    ) { }
}

const owtHomePageModel = new OwtHomePageModel();

fixture`OWT homepage`
  .page(process.env.HOST);

test.only('Should have search results for "SBB"', async (t) => {

  const firstSearchEntry = 'Empowering the Digitalization of the Gotthard Base Tunnel with Augmented Reality';

  const searchIcon = owtHomePageModel.searchIcon;
  const searchInput = owtHomePageModel.searchInput;

  await t
    .click(searchIcon)
    .typeText(searchInput, 'SBB')
    .pressKey('enter');

  const searchResultsFirstTitle = owtHomePageModel.searchResultItems.find('.title').nth(0);

  await t
    .expect(searchResultsFirstTitle.innerText).contains(firstSearchEntry);
});

Specify your

LavrovArtem commented 6 years ago

Hi @dweber019, I've reproduced the problem and I will investigate it.

LavrovArtem commented 6 years ago

The fix is published in testcafe@0.20.0-alpha.1.

dweber019 commented 6 years ago

@LavrovArtem when will version 0.20.0 be released?

AlexanderMoskovkin commented 6 years ago

@dweber019 I guess it can take one or two weeks

SayedShahidi commented 6 years ago

Is this issue fixed because I still have the issue and i am using version 0.20.2.

miherlosev commented 6 years ago

Hi @SayedShahidi

I cannot reproduce the issue because site markup was changed and test from description now failed. Could you please provide a simple example to reproduce?

lock[bot] commented 5 years ago

This thread has been automatically locked since it is closed and there has not been any recent activity. Please open a new issue for related bugs or feature requests. We recommend you ask TestCafe API, usage and configuration inquiries on StackOverflow.