File tree Expand file tree Collapse file tree 4 files changed +114
-0
lines changed Expand file tree Collapse file tree 4 files changed +114
-0
lines changed Original file line number Diff line number Diff line change
1
+ (package "check-clean" "0.0.1" "mock package")
2
+
3
+ (package-file "lint.el")
4
+
5
+ (source 'gnu)
6
+
7
+ (eask-defcommand my-command
8
+ "This is a command"
9
+ (message "hello world"))
10
+
11
+ (eask-defcommand my-warn
12
+ (warn "A warning"))
13
+
14
+ (eask-defcommand my-error
15
+ (error "An error"))
16
+
17
+ (script "hello" "echo 'hello'")
18
+ (script "warn" "eask" "run" "command" "my-warn")
19
+ (script "exit" "exit" "1")
Original file line number Diff line number Diff line change
1
+ ; ;; lint.el --- Test the command package -*- lexical-binding : t ; -*-
2
+
3
+ ; ; Copyright (C) 2022-2024 the Eask authors.
4
+
5
+ ; ; This program is free software; you can redistribute it and/or modify
6
+ ; ; it under the terms of the GNU General Public License as published by
7
+ ; ; the Free Software Foundation, either version 3 of the License, or
8
+ ; ; (at your option) any later version.
9
+
10
+ ; ; This program is distributed in the hope that it will be useful,
11
+ ; ; but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ ; ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
+ ; ; GNU General Public License for more details.
14
+
15
+ ; ; You should have received a copy of the GNU General Public License
16
+ ; ; along with this program. If not, see <https://www.gnu.org/licenses/>.
17
+
18
+ ; ;; Version: 0.0.1
19
+
20
+ ; ;; Commentary:
21
+
22
+ ; ;; Code:
23
+
24
+ (declare-function ignore " subr.el" (&rest args))
25
+
26
+ (provide 'lint )
27
+
28
+ ; ;; lint.el ends here
Original file line number Diff line number Diff line change
1
+ (package "check-clean" "0.0.1" "mock package")
2
+
3
+ (package-file "lint.el")
4
+
5
+ (source 'gnu)
6
+
7
+ (eask-defcommand my-command
8
+ "This is a command"
9
+ (message "hello world"))
10
+
11
+ (eask-defcommand my-warn
12
+ (warn "A warning"))
13
+
14
+ (eask-defcommand my-error
15
+ (error "An error"))
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+
3
+ # Copyright (C) 2022-2024 the Eask authors.
4
+
5
+ # This program is free software; you can redistribute it and/or modify
6
+ # it under the terms of the GNU General Public License as published by
7
+ # the Free Software Foundation; either version 3, or (at your option)
8
+ # any later version.
9
+
10
+ # This program is distributed in the hope that it will be useful,
11
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
+ # GNU General Public License for more details.
14
+
15
+ # You should have received a copy of the GNU General Public License
16
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
17
+
18
+ # # Commentary:
19
+ #
20
+ # Tests "run" command
21
+
22
+ set -e
23
+
24
+ source ./test/fixtures/home/scripts/testing.sh
25
+ cd $( dirname " $0 " )
26
+
27
+ should_error eask run
28
+ # FIXME
29
+ # should_error eask run command
30
+ # FIXME
31
+ # cd ./no-scripts/
32
+ # should_error eask run script
33
+ # cd ../
34
+
35
+ should_run eask run command my-command my-warn
36
+ # FIXME
37
+ # should_error eask run command --strict my-command my-warn
38
+
39
+ # FIXME stack trace
40
+ should_error eask run command my-error
41
+
42
+ OUTPUT=" $( should_error eask run command --allow-error my-error my-command) "
43
+ # FIXME
44
+ # should_match "hello world" "$OUTPUT"
45
+
46
+ should_run eask run script hello
47
+ should_run eask run script hello foo
48
+ # FIXME
49
+ # should_error eask run script --strict hello foo
50
+
51
+ # FIXME this doesn't actually run the script
52
+ should_run eask run script warn
You can’t perform that action at this time.
0 commit comments