Skip to content
Snippets Groups Projects
Verified Commit c3b0d0c7 authored by Damien's avatar Damien
Browse files

FEAT #13675 TIME 3:20 Add protractor + begin test

parent b90f8bdb
No related branches found
No related tags found
No related merge requests found
......@@ -64,6 +64,7 @@
"node-sass": "^4.13.1",
"nodemon": "^2.0.2",
"npm-check-updates": "^4.1.0",
"protractor": "^5.4.3",
"rxjs": "^6.5.4",
"typescript": "3.8.3",
"url-loader": "^4.0.0",
......
......@@ -53,4 +53,4 @@
<button id="snav2Button" mat-icon-button (click)="this.snav2.toggle()">
<mat-icon class="fa fa-2x" [ngClass]="[this.snav2 && this.snav2.opened ? 'fa-chevron-right' : 'fa-chevron-left']"></mat-icon>
</button>
</mat-toolbar>
\ No newline at end of file
</mat-toolbar>
describe('about-us page', function() {
it('test page', function() {
browser.sleep(2000);
element(by.css('[title="Accueil"]')).click();
browser.sleep(2000);
});
});
exports.config = {
seleniumAddress: 'http://localhost:4444/wd/hub',
specs: [
'login-spec.js',
'about-us-spec.js'
]
};
describe('angular homepage todo list', function() {
it('should add a todo', function() {
browser.waitForAngularEnabled(false);
browser.get('http://127.0.0.1/maarch_trunk/apps/maarch_entreprise/index.php?display=true&page=login');
element(by.id('login')).sendKeys('bbain');
element(by.id('pass')).sendKeys('maarch');
element(by.css('[name="submit"]')).click();
// var todoList = element.all(by.repeater('todo in todoList.todos'));
// expect(todoList.count()).toEqual(3);
// expect(todoList.get(2).getText()).toEqual('write first protractor test');
//
// // You wrote your first test, cross it off the list
// todoList.get(2).element(by.css('input')).click();
// var completedAmount = element.all(by.css('.done-true'));
// expect(completedAmount.count()).toEqual(2);
});
it('test 2', function() {
browser.sleep(4000);
browser.waitForAngularEnabled(true);
var nbHeader = element.all(by.css('[class="bg-head-content"]'));
expect(nbHeader.count()).toEqual(1);
element(by.css('[routerLink="/about-us"]')).click();
});
});
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment