Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci/coq-tests: expect 060_coq-test-wholefile to fail for 8.17 #699

Merged
merged 1 commit into from
Apr 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ci/coq-tests.el
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,8 @@ For example, COMMENT could be (*test-definition*)"


(ert-deftest 060_coq-test-wholefile ()
;; test_wholefile.v triggers a fatal warning in 8.17, see also #698
:expected-result (if (coq--post-v817) :failed :passed)
"Test `proof-process-buffer'."
(coq-fixture-on-file
(coq-test-full-path "test_wholefile.v")
Expand Down
12 changes: 12 additions & 0 deletions coq/coq-system.el
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,18 @@ Return nil if the version cannot be detected."
(signal 'coq-unclassifiable-version coq-version-to-use))
(t (signal (car err) (cdr err))))))))

(defun coq--post-v817 ()
"Return t if the auto-detected version of Coq is >= 8.17.
Return nil if the version cannot be detected."
(let ((coq-version-to-use (or (coq-version t) "8.16")))
(condition-case err
(not (coq--version< coq-version-to-use "8.17"))
(error
(cond
((equal (substring (cadr err) 0 15) "Invalid version")
(signal 'coq-unclassifiable-version coq-version-to-use))
(t (signal (car err) (cdr err))))))))

(defun coq--supports-topfile ()
"Return t if \"-topfile\" appears in coqtop options"
(string-match "-topfile" coq-autodetected-help)
Expand Down