Closed Kiattikhun-W closed 7 months ago
Hi @Kiattikhun-W
Thanks for submitting an issue, I've already created a Pull Request for this, see https://github.com/webdriverio/visual-testing/pull/219. I'm waiting for a review and hope to release it this week.
Hi @Kiattikhun-W
We've released a new version, please try the latest one and make sure you use it like this
import { remote } from 'webdriverio'
import VisualService from '@wdio/visual-service'
let visualService = new VisualService({
autoSaveBaseline: true
})
const browser = await remote({
logLevel: 'silent',
capabilities: {
browserName: 'chrome',
}
})
// "Start" the service to add the custom commands to the `browser`
visualService.remoteSetup(browser)
await browser.url('https://webdriver.io/')
// or use this for ONLY saving a screenshot
await browser.saveFullPageScreen('examplePaged', {})
// or use this for validating. Both methods don't need to be combined, see the FAQ
await browser.checkFullPageScreen('examplePaged', {})
await browser.deleteSession()
Environment (please complete the following information):
@wdio/visual-service
version: 3.0.2Config of WebdriverIO +
@wdio/visual-service
Describe the bug error at
await visualService.before(browser.capabilities);
To Reproduce Steps to reproduce the behavior:
Expected behavior Able to use the function of visual-testing service.