Manually calculate scroll offset in test
This commit is contained in:
@@ -275,7 +275,14 @@ describe('browser/settings.html', function desc() {
|
||||
const selected = await this.app.client.isSelected('#inputSpellChecker');
|
||||
selected.should.equal(true);
|
||||
|
||||
await this.app.client.click('#inputSpellChecker').pause(700);
|
||||
const windowBounds = await this.app.browserWindow.getBounds();
|
||||
const inputLocation = await this.app.client.getLocation('#inputSpellChecker');
|
||||
const offset = (inputLocation.y - windowBounds.height) + 100;
|
||||
|
||||
await this.app.client.
|
||||
scroll(0, offset).
|
||||
click('#inputSpellChecker').
|
||||
pause(5000);
|
||||
const config1 = JSON.parse(fs.readFileSync(env.configFilePath, 'utf-8'));
|
||||
config1.useSpellChecker.should.equal(false);
|
||||
});
|
||||
|
Reference in New Issue
Block a user