0

I should make e2e tests on Gojs nodes.

The limitation is that GoJs generates canvas graphes so I'm not able to select nodes.

I found a post mentioning this problem here

In the code sample Robot.js is written inside the same scope of the diagram.

But in Angular e2e tests I don't have access the the goJS object because tests are on a separate files.

I would like to know how can I make use of Robot.js to test GoJS graphs ( click on node for example ) in Angular e2e tests ?

import { LoginPage } from './login.po';
import { browser, logging, element, by } from 'protractor';

describe('Login page test', () => {
    let page: LoginPage;

    beforeEach(() => {
        page = new LoginPage();
    });

    it('Login button should activate with login and pass', () => {
        page.navigateTo();
        expect(page.getButtonDisabledStatus()).toEqual('true');
        page.fillLoginPassWith('user', 'password')
        expect(page.getButtonDisabledStatus()).toBeNull();
    });

});
infodev
  • 4,673
  • 17
  • 65
  • 138

0 Answers0