import {LoginPo} from './login.po';


describe('Login Module', () => {
  let loginPo: LoginPo;

  beforeEach(() => {
    loginPo = new LoginPo();
  });

  it('Check if login form displayed!', async () => {
    await loginPo.navigateTo();
    expect(await loginPo.getTitleText()).toEqual('Sign in');
  });

  it('Process login form!', async () => {
    await loginPo.navigateTo();
    await loginPo.processForm();
    expect(await loginPo.dashboardPresent()).toEqual(true);
    expect(await loginPo.loggedUser()).toEqual(' TESTINS');
    await loginPo.logout();
  });
});
