File tree 1 file changed +34
-0
lines changed 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change 16
16
(should (equal '(" Test" " test-1" " bench-1" " bin-1" )
17
17
(haskell-cabal-enum-targets)))))
18
18
19
+ (ert-deftest haskell-cabal-guess-setting-1 ()
20
+ (with-temp-buffer
21
+ (let ((scriptDir
22
+ (file-name-directory
23
+ (or (symbol-file 'haskell-cabal-guess-setting-1 )
24
+ (buffer-file-name )))))
25
+ (set-visited-file-name (expand-file-name " test-data/Source.hs" scriptDir) t t ))
26
+ (should (equal " Simple"
27
+ (haskell-cabal-guess-setting " build-type" )))))
28
+
29
+ (ert-deftest haskell-cabal-compute-checksum-1 ()
30
+ (let ((scriptDir
31
+ (file-name-directory
32
+ (or (symbol-file 'haskell-cabal-guess-setting-1 )
33
+ (buffer-file-name )))))
34
+
35
+ (should (equal " 263e67082326a27585639420f4d42c8b"
36
+ (haskell-cabal-compute-checksum (expand-file-name " test-data" scriptDir))))))
37
+
38
+ (ert-deftest haskell-cabal-compute-next-prev-section-1 ()
39
+ (let ((scriptDir
40
+ (file-name-directory
41
+ (or (symbol-file 'haskell-cabal-guess-setting-1 )
42
+ (buffer-file-name )))))
43
+
44
+ (with-temp-buffer
45
+ (insert-file-contents (expand-file-name " test-data/Test.cabal" scriptDir))
46
+ (haskell-cabal-mode )
47
+ (goto-char (point-min ))
48
+ (haskell-cabal-next-section)
49
+ (haskell-cabal-next-subsection)
50
+ (haskell-cabal-previous-subsection)
51
+ (haskell-cabal-previous-section))))
52
+
19
53
(provide 'haskell-cabal-tests )
20
54
21
55
; ;; haskell-cabal-tests.el ends here
You can’t perform that action at this time.
0 commit comments