diff options
| author | João Távora | 2025-01-20 17:42:59 +0000 |
|---|---|---|
| committer | João Távora | 2025-01-20 17:43:35 +0000 |
| commit | a1ce633ca9be91c4acba4125cdabc5b6f600e5ff (patch) | |
| tree | b5cc6fbf11efae9d2b4bb8349b4b24872e5d6bdf /test | |
| parent | 73f51f3a99ed454fa57e5ebe177df00cada1f11a (diff) | |
| download | emacs-a1ce633ca9be91c4acba4125cdabc5b6f600e5ff.tar.gz emacs-a1ce633ca9be91c4acba4125cdabc5b6f600e5ff.zip | |
Eglot: make eglot-test-javascript-basic more robust
* test/lisp/progmodes/eglot-tests.el
(eglot-test-javascript-basic): Mark test expensive and increase timeout.
Diffstat (limited to 'test')
| -rw-r--r-- | test/lisp/progmodes/eglot-tests.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el index 10e8fb1d41b..2dc45df7d9e 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el | |||
| @@ -866,6 +866,7 @@ int main() { | |||
| 866 | 866 | ||
| 867 | (ert-deftest eglot-test-javascript-basic () | 867 | (ert-deftest eglot-test-javascript-basic () |
| 868 | "Test basic autocompletion in a JavaScript LSP." | 868 | "Test basic autocompletion in a JavaScript LSP." |
| 869 | :tags '(:expensive-test) | ||
| 869 | (skip-unless (and (executable-find "typescript-language-server") | 870 | (skip-unless (and (executable-find "typescript-language-server") |
| 870 | (executable-find "tsserver"))) | 871 | (executable-find "tsserver"))) |
| 871 | (eglot--with-fixture | 872 | (eglot--with-fixture |
| @@ -880,14 +881,14 @@ int main() { | |||
| 880 | :client-notifications | 881 | :client-notifications |
| 881 | c-notifs) | 882 | c-notifs) |
| 882 | (should (eglot--tests-connect)) | 883 | (should (eglot--tests-connect)) |
| 883 | (eglot--wait-for (s-notifs 2) (&key method &allow-other-keys) | 884 | (eglot--wait-for (s-notifs 10) (&key method &allow-other-keys) |
| 884 | (string= method "textDocument/publishDiagnostics")) | 885 | (string= method "textDocument/publishDiagnostics")) |
| 885 | (should (not (eq 'flymake-error (face-at-point)))) | 886 | (should (not (eq 'flymake-error (face-at-point)))) |
| 886 | (insert "{") | 887 | (insert "{") |
| 887 | (eglot--signal-textDocument/didChange) | 888 | (eglot--signal-textDocument/didChange) |
| 888 | (eglot--wait-for (c-notifs 1) (&key method &allow-other-keys) | 889 | (eglot--wait-for (c-notifs 1) (&key method &allow-other-keys) |
| 889 | (string= method "textDocument/didChange")) | 890 | (string= method "textDocument/didChange")) |
| 890 | (eglot--wait-for (s-notifs 2) (&key params method &allow-other-keys) | 891 | (eglot--wait-for (s-notifs 10) (&key params method &allow-other-keys) |
| 891 | (and (string= method "textDocument/publishDiagnostics") | 892 | (and (string= method "textDocument/publishDiagnostics") |
| 892 | (cl-destructuring-bind (&key _uri diagnostics) params | 893 | (cl-destructuring-bind (&key _uri diagnostics) params |
| 893 | (cl-find-if (jsonrpc-lambda (&key severity &allow-other-keys) | 894 | (cl-find-if (jsonrpc-lambda (&key severity &allow-other-keys) |