From 008353849107d2bd26876f86adc385009476ba2e Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Fri, 25 Mar 2016 18:21:38 +0100 Subject: [PATCH] Add basic test for spawning userscripts --- tests/integration/data/userscripts/open_current_url | 3 +++ tests/integration/features/spawn.feature | 7 +++++++ 2 files changed, 10 insertions(+) create mode 100755 tests/integration/data/userscripts/open_current_url diff --git a/tests/integration/data/userscripts/open_current_url b/tests/integration/data/userscripts/open_current_url new file mode 100755 index 000000000..6d7f6dc36 --- /dev/null +++ b/tests/integration/data/userscripts/open_current_url @@ -0,0 +1,3 @@ +#!/bin/bash + +echo "open -t $QUTE_URL" >> "$QUTE_FIFO" diff --git a/tests/integration/features/spawn.feature b/tests/integration/features/spawn.feature index 5ebd4f4a3..3f31a7acc 100644 --- a/tests/integration/features/spawn.feature +++ b/tests/integration/features/spawn.feature @@ -15,3 +15,10 @@ Feature: :spawn Scenario: Running :spawn with url variable When I run :spawn echo {url} Then "Executing echo with args ['about:blank'], userscript=False" should be logged + + Scenario: Running :spawn with userscript + When I run :spawn --userscript open_current_url + And I wait until about:blank is loaded + Then the following tabs should be open: + - about:blank + - about:blank (active)