mirror of
https://github.com/divkit/divkit.git
synced 2026-06-06 20:07:59 +00:00
Visibility actions in gallery
This commit is contained in:
@@ -26,9 +26,6 @@ describe('regression', () => {
|
||||
offset: 300
|
||||
});
|
||||
await this.browser.assertView('right_swipe', '#root');
|
||||
|
||||
const logs = await this.browser.execute(() => window.divkitLogs);
|
||||
logs.length.should.equal(2);
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
describe('regression', () => {
|
||||
describe('Visibility_actions in gallery', () => {
|
||||
beforeEach(async function() {
|
||||
await this.browser.execute(() => {
|
||||
window.divkitLogs = [];
|
||||
});
|
||||
await this.browser.yaOpenRegressionJson('gallery/gallery_swipe');
|
||||
});
|
||||
|
||||
hermione.only.in('chromeMobile', 'pointerType="touch" is not supported on firefox');
|
||||
it('Horizontal swipe visibility action', async function() {
|
||||
// Wait for visibility action logging
|
||||
await this.browser.pause(1000);
|
||||
await this.browser.yaSwipe({
|
||||
selector: 'div[role=tabpanel]',
|
||||
direction: 'left',
|
||||
duration: 500,
|
||||
offset: 300
|
||||
});
|
||||
await this.browser.assertView('swipe_left__action', '#root');
|
||||
|
||||
await this.browser.yaSwipe({
|
||||
selector: 'div[role=tabpanel]',
|
||||
direction: 'right',
|
||||
duration: 500,
|
||||
offset: 300
|
||||
});
|
||||
await this.browser.assertView('swipe_right__action', '#root');
|
||||
|
||||
let logs = await this.browser.execute(() => window.divkitLogs);
|
||||
logs = logs.map(log => log.action.log_id);
|
||||
logs[0].should.equal('item/01');
|
||||
logs[1].should.equal('item/02');
|
||||
logs[2].should.equal('item/01');
|
||||
});
|
||||
});
|
||||
});
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
describe('regression', () => {
|
||||
describe('Visibility_actions in pager', () => {
|
||||
describe('Visibility actions in pager', () => {
|
||||
beforeEach(async function() {
|
||||
await this.browser.execute(() => {
|
||||
window.divkitLogs = [];
|
||||
|
||||
BIN
Binary file not shown.
|
After Width: | Height: | Size: 25 KiB |
BIN
Binary file not shown.
|
After Width: | Height: | Size: 22 KiB |
@@ -863,6 +863,9 @@
|
||||
},
|
||||
{
|
||||
"title": "Visibility actions in gallery",
|
||||
"automated": [
|
||||
"web"
|
||||
],
|
||||
"tags": [
|
||||
"visibility_actions"
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user