Skip to content
Snippets Groups Projects
Select Git revision
  • 3cd27f93e28396ed725dfe83e6facd7e18c593e4
  • master default protected
  • 10-unl-ru
3 results

app.py

Blame
  • main.js 753 B
    describe('Open example', () => {
      beforeAll(async () => {
        await page.goto('https://example.org');
      });
      it('has the correct page title', async () => {
        const title = await page.title();
        expect(title).toBe('Example Domain');
      });
      it('has the main text', async () => {
        await expect(page).toMatchElement('a[href="https://www.iana.org/domains/example"]');
      });
    });
    
    describe('Open local HTTP server', () => {
      beforeAll(async () => {
        await page.goto('http://127.0.0.1:4488');
      });
      it('has the correct page title', async () => {
        const title = await page.title();
        expect(title).toBe('Index of /');
      });
      it('has the correct link', async () => {
        await expect(page).toMatchElement('a[href="./jest.json"]');
      });
    });