How to select a single item in protractor
You can get an indexed element from an array returned with // Get the 5th element matching the .dfdf css selector element.all(by.css(‘.dfdf’)).get(4).sendKeys(‘foo’);
You can get an indexed element from an array returned with // Get the 5th element matching the .dfdf css selector element.all(by.css(‘.dfdf’)).get(4).sendKeys(‘foo’);
I encounter Can’t resolve all parameters for ElementRef: (?) Error using the mock from @gilad-s in angular 2.4 Modified the mock class to: export class MockElementRef extends ElementRef { constructor() { super(null); } } resolves the test error. Reading from the angular source code here: https://github.com/angular/angular/blob/master/packages/core/testing/src/component_fixture.ts#L17-L60 the elementRef of the fixture is not created from …