From 5b6baee1aeb1072ddfb0ecbd82b611396187766f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Mon, 10 Jan 2022 14:18:10 +0100 Subject: [PATCH] MOBILE-3833 swipe: Change swipe to directive --- tests/behat/app_behat_runtime.js | 6 +++--- tests/behat/behat_app.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/behat/app_behat_runtime.js b/tests/behat/app_behat_runtime.js index a9c3df3cf..1567ac68a 100644 --- a/tests/behat/app_behat_runtime.js +++ b/tests/behat/app_behat_runtime.js @@ -734,8 +734,8 @@ * @param {string} className Constructor class name * @return {object} Component instance */ - const behatGetComponentInstance = function(selector, className) { - log('Action - Get component instance ' + selector + ', ' + className); + const behatGetAngularInstance = function(selector, className) { + log('Action - Get Angular instance ' + selector + ', ' + className); const activeElement = Array.from(document.querySelectorAll(`.ion-page:not(.ion-page-hidden) ${selector}`)).pop(); @@ -757,6 +757,6 @@ press : behatPress, setField : behatSetField, getHeader : behatGetHeader, - getComponentInstance: behatGetComponentInstance, + getAngularInstance: behatGetAngularInstance, }; })(); diff --git a/tests/behat/behat_app.php b/tests/behat/behat_app.php index 051e8560b..d36f1f405 100644 --- a/tests/behat/behat_app.php +++ b/tests/behat/behat_app.php @@ -237,7 +237,7 @@ class behat_app extends behat_base { public function i_swipe_in_the_app(string $direction) { $method = 'swipe' . ucwords($direction); - $this->evaluate_script("behat.getComponentInstance('core-swipe-navigation', 'CoreSwipeNavigationComponent').$method()"); + $this->evaluate_script("behat.getAngularInstance('ion-content', 'CoreSwipeNavigationDirective').$method()"); } /**