summaryrefslogtreecommitdiffstats
path: root/pkg/integration/components/test_driver.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/integration/components/test_driver.go')
-rw-r--r--pkg/integration/components/test_driver.go9
1 files changed, 8 insertions, 1 deletions
diff --git a/pkg/integration/components/test_driver.go b/pkg/integration/components/test_driver.go
index 7b3fb0889..f2604d211 100644
--- a/pkg/integration/components/test_driver.go
+++ b/pkg/integration/components/test_driver.go
@@ -16,14 +16,16 @@ type TestDriver struct {
keys config.KeybindingConfig
pushKeyDelay int
*assertionHelper
+ shell *Shell
}
-func NewTestController(gui integrationTypes.GuiDriver, keys config.KeybindingConfig, pushKeyDelay int) *TestDriver {
+func NewTestDriver(gui integrationTypes.GuiDriver, shell *Shell, keys config.KeybindingConfig, pushKeyDelay int) *TestDriver {
return &TestDriver{
gui: gui,
keys: keys,
pushKeyDelay: pushKeyDelay,
assertionHelper: &assertionHelper{gui: gui},
+ shell: shell,
}
}
@@ -67,6 +69,11 @@ func (self *TestDriver) Log(message string) {
self.gui.LogUI(message)
}
+// allows the user to run shell commands during the test to emulate background activity
+func (self *TestDriver) Shell() *Shell {
+ return self.shell
+}
+
// this will look for a list item in the current panel and if it finds it, it will
// enter the keypresses required to navigate to it.
// The test will fail if: