mirror of
https://github.com/kforney/pentest-distro-builder.git
synced 2024-05-16 15:34:50 -06:00
Kaj Forney
582f5b5f5c
Former-commit-id: 09eacc3f3f761c2b3454d20356ba085d18bdb722 Former-commit-id: 89d8a1302bd2a72239fbe9ad9820be4ecda76cab
25 lines
681 B
Bash
Executable file
25 lines
681 B
Bash
Executable file
#/usr/bin/env bash
|
|
|
|
CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|
|
|
# bash helpers provided by 'tmux-test'
|
|
source $CURRENT_DIR/helpers/helpers.sh
|
|
|
|
# installs plugin from current repo in Vagrant (or on Travis)
|
|
install_tmux_plugin_under_test_helper
|
|
|
|
# start tmux in background (plugin under test is sourced)
|
|
tmux new -d
|
|
|
|
# get first session name
|
|
session_name="$(tmux list-sessions -F "#{session_name}")"
|
|
|
|
# fail the test if first session name is not "0"
|
|
if ! [ "$session_name" == "0" ]; then
|
|
# fail_helper is also provided by 'tmux-test'
|
|
fail_helper "First session name is not '0' by default"
|
|
fi
|
|
|
|
# sets the right script exit code ('tmux-test' helper)
|
|
exit_helper
|