Welcome to mirror list, hosted at ThFree Co, Russian Federation.

ReferBanner_spec.js « UI « tests « Feedback « plugins - github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 84b8c1bb339af2ff2735fe54a670fd9f0b132772 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*!
 * Matomo - free/libre analytics platform
 *
 * UsersManager screenshot tests.
 *
 * @link https://matomo.org
 * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
 */

describe("ReferBannerTest", function () {
    this.timeout(0);
    this.fixture = "Piwik\\Plugins\\Feedback\\tests\\Fixtures\\ReferBannerFixture";

    var url = "?module=CoreHome&action=index&idSite=1&period=day&date=2019-07-11&forceFeedbackTest=1";

    before(async function() {
        await page.webpage.setViewport({
            width: 1250,
            height: 768
        });
    });

    it('should display popup when next reminder date is in past', async function () {
        await page.goto(url);
        await page.waitForNetworkIdle();

        var banner = await page.waitForSelector('.refer-banner', { visible: true });
        expect(await banner.screenshot()).to.matchImage('feedback_popup');
    });
});