summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2017-07-20 15:08:18 +0200
committerRuben Pollan <meskio@sindominio.net>2017-07-20 21:23:16 +0200
commitbd24e2024ad29fa72cae661ac5898cad4ace8e8b (patch)
treefdb27043b91fefc7d2bc95e83cbd948900f15ec8
parent702cb93e24d313bab428881876d94fd10098bf2f (diff)
[test] enable and check vpn
-rw-r--r--tests/functional/features/smoke.feature7
-rw-r--r--tests/functional/features/steps/vpn.py18
2 files changed, 24 insertions, 1 deletions
diff --git a/tests/functional/features/smoke.feature b/tests/functional/features/smoke.feature
index 6209ad6a..efa3cad7 100644
--- a/tests/functional/features/smoke.feature
+++ b/tests/functional/features/smoke.feature
@@ -1,4 +1,3 @@
-@smoke
Feature: login and logout
Scenario: See user panel after login
@@ -12,3 +11,9 @@ Feature: login and logout
And I logout
Then I should see the second login page
+ @smoke
+ Scenario: Use VPN
+ Given I start bitmask for the first time
+ When I login
+ And I activate VPN
+ Then I should have my ass covered
diff --git a/tests/functional/features/steps/vpn.py b/tests/functional/features/steps/vpn.py
new file mode 100644
index 00000000..f08c2af7
--- /dev/null
+++ b/tests/functional/features/steps/vpn.py
@@ -0,0 +1,18 @@
+from behave import when, then
+from common import (
+ click_button,
+ wait_until_button_is_visible,
+ find_element_containing_text
+)
+
+
+@when('I activate VPN')
+def activate_vpn(context):
+ click_button(context, 'Install Helper Files')
+ click_button(context, 'Turn ON')
+
+
+@then('I should have my ass covered')
+def assert_vpn(context):
+ wait_until_button_is_visible(context, 'Turn OFF')
+ assert find_element_containing_text(context, 'Turn OFF', 'button')