aboutsummaryrefslogtreecommitdiffstats
path: root/test/integration/oni-org.bats
blob: 1b20e68cb2964b66d1839ddba098d0019c9f8d8f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/usr/bin/env bats

@test "Opening a .org file loads oni-org" {
    run emacs -batch -l package -f package-initialize \
        -visit test.org \
        -eval "(prin1 (featurep 'oni-org))"

    echo "$output"

    [[ "$output" == *"t" ]]
}

@test "Loading org-edna diminishes org-edna-mode" {
    run emacs -batch -l package -f package-initialize -l subr-x \
        -l org-edna \
        -eval "(prin1 (string-empty-p (car (alist-get 'org-edna-mode minor-mode-alist))))"

    echo "$output"

    [[ "$output" == *"t" ]]
}

@test "Reloading org-edna diminishes org-edna-mode" {
    run emacs -batch -l package -f package-initialize -l subr-x \
        -l org-edna \
        -eval "(prin1 (string-empty-p (car (alist-get 'org-edna-mode minor-mode-alist))))"

    echo "$output"

    [[ "$output" == *"t" ]]
}