#!/usr/bin/env bats setup() { mkdir -p content/users/test } @test "Basic choice" { echo "--- title: Basic test --- " > content/test.md echo "--- title: Basic choice test ac_choices: - \"[abc](/home)\" - \"[def](/test)\" - \"[ghi](/home)\" --- " > content/users/test/choice_test.md echo "ac_choice=1" > content/users/test/choice_test.choice [ -e content/users/test/choice_test.md ] [ -e content/users/test/choice_test.choice ] bin/ac_route.sh "$(pwd)/content/users/test" choice_test.choice [ ! -e content/users/test/choice_test.md ] [ ! -e content/users/test/choice_test.choice ] [ -e content/users/test/choice_test.result ] [ -e content/users/test/test.md ] } teardown() { rm -f content/test.md rm -rf content/users }