diff options
| author | Michael Albinus | 2025-10-11 14:37:04 +0200 |
|---|---|---|
| committer | Michael Albinus | 2025-10-11 14:37:04 +0200 |
| commit | ba7e9579260e146d53d1fc039ff2035ff45fca75 (patch) | |
| tree | 7544db18e58341013ef0486f7dfd4e1b63681f59 | |
| parent | dcea973c04bc9f1078444dc1faf9491408832423 (diff) | |
| download | emacs-ba7e9579260e146d53d1fc039ff2035ff45fca75.tar.gz emacs-ba7e9579260e146d53d1fc039ff2035ff45fca75.zip | |
Make cascaded archives working in tramp-archive.el work, again
* lisp/net/tramp-archive.el (tramp-archive-file-name-handler):
Move bindings of `tramp-methods' and `tramp-gvfs-methods' up.
(tramp-archive-file-name-handler): Do not use
`tramp-archive-run-real-handler' for testing existence of
`archive'. (Bug#79582)
* test/lisp/net/tramp-archive-tests.el
(tramp-archive-test-file-archive-hexlified): Move down.
(tramp-archive-test-cascaded-file-archive)
(tramp-archive-test-cascaded-archive, tramp-archive-test-cascaded):
New defvars.
(tramp-archive--test-deftest-cascaded): New defmacro.
(tramp-archive-test01-file-name-syntax)
(tramp-archive-test05-expand-file-name): Adapt tests.
(tramp-archive-test01-file-name-syntax-cascaded)
(tramp-archive-test05-expand-file-name-cascaded)
(tramp-archive-test06-directory-file-name-cascaded)
(tramp-archive-test07-file-exists-p-cascaded)
(tramp-archive-test08-file-local-copy-cascaded)
(tramp-archive-test09-insert-file-contents-cascaded)
(tramp-archive-test11-copy-file-cascaded)
(tramp-archive-test15-copy-directory-cascaded)
(tramp-archive-test16-directory-files-cascaded)
(tramp-archive-test17-insert-directory-cascaded)
(tramp-archive-test18-file-attributes-cascaded)
(tramp-archive-test19-directory-files-and-attributes-cascaded)
(tramp-archive-test20-file-modes-cascaded)
(tramp-archive-test21-file-links-cascaded)
(tramp-archive-test26-file-name-completion-cascaded)
(tramp-archive-test40-make-nearby-temp-file-cascaded)
(tramp-archive-test43-file-system-info-cascaded)
(tramp-archive-test44-user-group-ids-cascaded): New tests.
* test/lisp/net/tramp-archive-resources/outer.zip: New test file.
| -rw-r--r-- | lisp/net/tramp-archive.el | 11 | ||||
| -rw-r--r-- | test/lisp/net/tramp-archive-resources/outer.zip | bin | 0 -> 444 bytes | |||
| -rw-r--r-- | test/lisp/net/tramp-archive-tests.el | 91 |
3 files changed, 85 insertions, 17 deletions
diff --git a/lisp/net/tramp-archive.el b/lisp/net/tramp-archive.el index 3de909911b4..a52b8be6e09 100644 --- a/lisp/net/tramp-archive.el +++ b/lisp/net/tramp-archive.el | |||
| @@ -338,15 +338,16 @@ arguments to pass to the OPERATION." | |||
| 338 | (tramp-register-file-name-handlers) | 338 | (tramp-register-file-name-handlers) |
| 339 | (tramp-archive-run-real-handler operation args)) | 339 | (tramp-archive-run-real-handler operation args)) |
| 340 | 340 | ||
| 341 | (let* ((filename (apply #'tramp-archive-file-name-for-operation | 341 | (let* ((tramp-methods (cons `(,tramp-archive-method) tramp-methods)) |
| 342 | (tramp-gvfs-methods tramp-archive-all-gvfs-methods) | ||
| 343 | (filename (apply #'tramp-archive-file-name-for-operation | ||
| 342 | operation args)) | 344 | operation args)) |
| 343 | (archive (tramp-archive-file-name-archive filename))) | 345 | (archive (tramp-archive-file-name-archive filename))) |
| 344 | 346 | ||
| 345 | ;; `filename' could be a quoted file name. Or the file | 347 | ;; `filename' could be a quoted file name. Or the file |
| 346 | ;; archive could be a directory, see Bug#30293. | 348 | ;; archive could be a directory, see Bug#30293. |
| 347 | (if (or (null archive) | 349 | (if (or (null archive) |
| 348 | (not (tramp-archive-run-real-handler | 350 | (not (file-exists-p archive)) |
| 349 | #'file-exists-p (list archive))) | ||
| 350 | (tramp-archive-run-real-handler | 351 | (tramp-archive-run-real-handler |
| 351 | #'file-directory-p (list archive))) | 352 | #'file-directory-p (list archive))) |
| 352 | (tramp-archive-run-real-handler operation args) | 353 | (tramp-archive-run-real-handler operation args) |
| @@ -358,9 +359,7 @@ arguments to pass to the OPERATION." | |||
| 358 | (tramp-get-buffer (tramp-archive-dissect-file-name filename)) | 359 | (tramp-get-buffer (tramp-archive-dissect-file-name filename)) |
| 359 | (setq default-directory (file-name-as-directory archive))) | 360 | (setq default-directory (file-name-as-directory archive))) |
| 360 | ;; Now run the handler. | 361 | ;; Now run the handler. |
| 361 | (let ((tramp-methods (cons `(,tramp-archive-method) tramp-methods)) | 362 | (let (;; Set uid and gid. gvfsd-archive could do it, but it doesn't. |
| 362 | (tramp-gvfs-methods tramp-archive-all-gvfs-methods) | ||
| 363 | ;; Set uid and gid. gvfsd-archive could do it, but it doesn't. | ||
| 364 | (tramp-unknown-id-integer (user-uid)) | 363 | (tramp-unknown-id-integer (user-uid)) |
| 365 | (tramp-unknown-id-string (user-login-name)) | 364 | (tramp-unknown-id-string (user-login-name)) |
| 366 | (fn (assoc operation tramp-archive-file-name-handler-alist))) | 365 | (fn (assoc operation tramp-archive-file-name-handler-alist))) |
diff --git a/test/lisp/net/tramp-archive-resources/outer.zip b/test/lisp/net/tramp-archive-resources/outer.zip new file mode 100644 index 00000000000..deda1013eb0 --- /dev/null +++ b/test/lisp/net/tramp-archive-resources/outer.zip | |||
| Binary files differ | |||
diff --git a/test/lisp/net/tramp-archive-tests.el b/test/lisp/net/tramp-archive-tests.el index 33dc0b9d4af..ec56c4a0f93 100644 --- a/test/lisp/net/tramp-archive-tests.el +++ b/test/lisp/net/tramp-archive-tests.el | |||
| @@ -36,12 +36,6 @@ | |||
| 36 | (defvar tramp-archive-test-file-archive (ert-resource-file "foo.tar.gz") | 36 | (defvar tramp-archive-test-file-archive (ert-resource-file "foo.tar.gz") |
| 37 | "The test file archive.") | 37 | "The test file archive.") |
| 38 | 38 | ||
| 39 | (defun tramp-archive-test-file-archive-hexlified () | ||
| 40 | "Return hexlified `tramp-archive-test-file-archive'. | ||
| 41 | Do not hexlify \"/\". This hexlified string is used in `file:///' URLs." | ||
| 42 | (let* ((url-unreserved-chars (cons ?/ url-unreserved-chars))) | ||
| 43 | (url-hexify-string tramp-archive-test-file-archive))) | ||
| 44 | |||
| 45 | (defvar tramp-archive-test-archive | 39 | (defvar tramp-archive-test-archive |
| 46 | (file-name-as-directory tramp-archive-test-file-archive) | 40 | (file-name-as-directory tramp-archive-test-file-archive) |
| 47 | "The test archive.") | 41 | "The test archive.") |
| @@ -50,11 +44,28 @@ Do not hexlify \"/\". This hexlified string is used in `file:///' URLs." | |||
| 50 | (file-truename (ert-resource-file "foo.iso")) | 44 | (file-truename (ert-resource-file "foo.iso")) |
| 51 | "A directory file name, which looks like an archive.") | 45 | "A directory file name, which looks like an archive.") |
| 52 | 46 | ||
| 47 | (defvar tramp-archive-test-cascaded-file-archive | ||
| 48 | (ert-resource-file "outer.zip/foo.tar.gz") | ||
| 49 | "The cascaded test file archive.") | ||
| 50 | |||
| 51 | (defvar tramp-archive-test-cascaded-archive | ||
| 52 | (file-name-as-directory tramp-archive-test-cascaded-file-archive) | ||
| 53 | "The cascaded test archive.") | ||
| 54 | |||
| 55 | (defun tramp-archive-test-file-archive-hexlified () | ||
| 56 | "Return hexlified `tramp-archive-test-file-archive'. | ||
| 57 | Do not hexlify \"/\". This hexlified string is used in `file:///' URLs." | ||
| 58 | (let* ((url-unreserved-chars (cons ?/ url-unreserved-chars))) | ||
| 59 | (url-hexify-string tramp-archive-test-file-archive))) | ||
| 60 | |||
| 53 | (setq password-cache-expiry nil | 61 | (setq password-cache-expiry nil |
| 54 | tramp-cache-read-persistent-data t ;; For auth-sources. | 62 | tramp-cache-read-persistent-data t ;; For auth-sources. |
| 55 | tramp-persistency-file-name nil | 63 | tramp-persistency-file-name nil |
| 56 | tramp-verbose 0) | 64 | tramp-verbose 0) |
| 57 | 65 | ||
| 66 | (defvar tramp-archive-test-cascaded nil | ||
| 67 | "Indicator, whether we are testing a cascaded archive.") | ||
| 68 | |||
| 58 | (defun tramp-archive--test-make-temp-name () | 69 | (defun tramp-archive--test-make-temp-name () |
| 59 | "Return a temporary file name for test. | 70 | "Return a temporary file name for test. |
| 60 | The temporary file is not created." | 71 | The temporary file is not created." |
| @@ -86,9 +97,29 @@ the origin of the temporary TMPFILE, have no write permissions." | |||
| 86 | (file-exists-p tramp-archive-test-file-archive) | 97 | (file-exists-p tramp-archive-test-file-archive) |
| 87 | (tramp-archive-file-name-p tramp-archive-test-archive)))) | 98 | (tramp-archive-file-name-p tramp-archive-test-archive)))) |
| 88 | 99 | ||
| 100 | ;; These tests are inspired by Bug#79582. | ||
| 101 | (defmacro tramp-archive--test-deftest-cascaded (test) | ||
| 102 | "Define ert `TEST-cascaded'." | ||
| 103 | (declare (indent 1)) | ||
| 104 | `(ert-deftest ,(intern (concat (symbol-name test) "-cascaded")) () | ||
| 105 | :tags '(:expensive-test) | ||
| 106 | ;(tramp--test-set-ert-test-documentation ',test "cascaded") | ||
| 107 | (skip-unless tramp-archive-enabled) | ||
| 108 | (if-let* ((ert-test (ert-get-test ',test)) | ||
| 109 | (result (ert-test-most-recent-result ert-test)) | ||
| 110 | (tramp-archive-test-file-archive | ||
| 111 | tramp-archive-test-cascaded-file-archive) | ||
| 112 | (tramp-archive-test-archive tramp-archive-test-cascaded-archive) | ||
| 113 | (tramp-archive-test-cascaded t)) | ||
| 114 | (progn | ||
| 115 | (skip-unless (< (ert-test-result-duration result) 300)) | ||
| 116 | (funcall (ert-test-body ert-test))) | ||
| 117 | (ert-skip (format "Test `%s' must run before" ',test))))) | ||
| 118 | |||
| 89 | (ert-deftest tramp-archive-test01-file-name-syntax () | 119 | (ert-deftest tramp-archive-test01-file-name-syntax () |
| 90 | "Check archive file name syntax." | 120 | "Check archive file name syntax." |
| 91 | (should-not (tramp-archive-file-name-p tramp-archive-test-file-archive)) | 121 | (unless tramp-archive-test-cascaded |
| 122 | (should-not (tramp-archive-file-name-p tramp-archive-test-file-archive))) | ||
| 92 | (should (tramp-archive-file-name-p tramp-archive-test-archive)) | 123 | (should (tramp-archive-file-name-p tramp-archive-test-archive)) |
| 93 | (should | 124 | (should |
| 94 | (string-equal | 125 | (string-equal |
| @@ -136,6 +167,8 @@ the origin of the temporary TMPFILE, have no write permissions." | |||
| 136 | (concat tramp-archive-test-archive "baz.tar/")) | 167 | (concat tramp-archive-test-archive "baz.tar/")) |
| 137 | "/"))) | 168 | "/"))) |
| 138 | 169 | ||
| 170 | (tramp-archive--test-deftest-cascaded tramp-archive-test01-file-name-syntax) | ||
| 171 | |||
| 139 | (ert-deftest tramp-archive-test02-file-name-dissect () | 172 | (ert-deftest tramp-archive-test02-file-name-dissect () |
| 140 | "Check archive file name components." | 173 | "Check archive file name components." |
| 141 | (skip-unless tramp-archive-enabled) | 174 | (skip-unless tramp-archive-enabled) |
| @@ -250,10 +283,13 @@ the origin of the temporary TMPFILE, have no write permissions." | |||
| 250 | (string-equal | 283 | (string-equal |
| 251 | (expand-file-name (concat tramp-archive-test-archive "./file")) | 284 | (expand-file-name (concat tramp-archive-test-archive "./file")) |
| 252 | (concat tramp-archive-test-archive "file"))) | 285 | (concat tramp-archive-test-archive "file"))) |
| 253 | (should | 286 | (unless tramp-archive-test-cascaded |
| 254 | (string-equal | 287 | (should |
| 255 | (expand-file-name (concat tramp-archive-test-archive "../file")) | 288 | (string-equal |
| 256 | (concat (ert-resource-directory) "file")))) | 289 | (expand-file-name (concat tramp-archive-test-archive "../file")) |
| 290 | (concat (ert-resource-directory) "file"))))) | ||
| 291 | |||
| 292 | (tramp-archive--test-deftest-cascaded tramp-archive-test05-expand-file-name) | ||
| 257 | 293 | ||
| 258 | ;; This test is inspired by Bug#30293. | 294 | ;; This test is inspired by Bug#30293. |
| 259 | (ert-deftest tramp-archive-test05-expand-file-name-non-archive-directory () | 295 | (ert-deftest tramp-archive-test05-expand-file-name-non-archive-directory () |
| @@ -332,6 +368,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 332 | (unhandled-file-name-directory | 368 | (unhandled-file-name-directory |
| 333 | (concat tramp-archive-test-archive "path/to/file")))) | 369 | (concat tramp-archive-test-archive "path/to/file")))) |
| 334 | 370 | ||
| 371 | (tramp-archive--test-deftest-cascaded tramp-archive-test06-directory-file-name) | ||
| 372 | |||
| 335 | (ert-deftest tramp-archive-test07-file-exists-p () | 373 | (ert-deftest tramp-archive-test07-file-exists-p () |
| 336 | "Check `file-exist-p', `write-region' and `delete-file'." | 374 | "Check `file-exist-p', `write-region' and `delete-file'." |
| 337 | :tags '(:expensive-test) | 375 | :tags '(:expensive-test) |
| @@ -355,6 +393,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 355 | ;; Cleanup. | 393 | ;; Cleanup. |
| 356 | (tramp-archive-cleanup-hash))) | 394 | (tramp-archive-cleanup-hash))) |
| 357 | 395 | ||
| 396 | (tramp-archive--test-deftest-cascaded tramp-archive-test07-file-exists-p) | ||
| 397 | |||
| 358 | (ert-deftest tramp-archive-test08-file-local-copy () | 398 | (ert-deftest tramp-archive-test08-file-local-copy () |
| 359 | "Check `file-local-copy'." | 399 | "Check `file-local-copy'." |
| 360 | :tags '(:expensive-test) | 400 | :tags '(:expensive-test) |
| @@ -382,6 +422,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 382 | (ignore-errors (tramp-archive--test-delete tmp-name)) | 422 | (ignore-errors (tramp-archive--test-delete tmp-name)) |
| 383 | (tramp-archive-cleanup-hash)))) | 423 | (tramp-archive-cleanup-hash)))) |
| 384 | 424 | ||
| 425 | (tramp-archive--test-deftest-cascaded tramp-archive-test08-file-local-copy) | ||
| 426 | |||
| 385 | (ert-deftest tramp-archive-test09-insert-file-contents () | 427 | (ert-deftest tramp-archive-test09-insert-file-contents () |
| 386 | "Check `insert-file-contents'." | 428 | "Check `insert-file-contents'." |
| 387 | :tags '(:expensive-test) | 429 | :tags '(:expensive-test) |
| @@ -409,6 +451,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 409 | ;; Cleanup. | 451 | ;; Cleanup. |
| 410 | (tramp-archive-cleanup-hash)))) | 452 | (tramp-archive-cleanup-hash)))) |
| 411 | 453 | ||
| 454 | (tramp-archive--test-deftest-cascaded tramp-archive-test09-insert-file-contents) | ||
| 455 | |||
| 412 | (ert-deftest tramp-archive-test11-copy-file () | 456 | (ert-deftest tramp-archive-test11-copy-file () |
| 413 | "Check `copy-file'." | 457 | "Check `copy-file'." |
| 414 | :tags '(:expensive-test) | 458 | :tags '(:expensive-test) |
| @@ -475,6 +519,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 475 | (ignore-errors (tramp-archive--test-delete tmp-name2)) | 519 | (ignore-errors (tramp-archive--test-delete tmp-name2)) |
| 476 | (tramp-archive-cleanup-hash)))) | 520 | (tramp-archive-cleanup-hash)))) |
| 477 | 521 | ||
| 522 | (tramp-archive--test-deftest-cascaded tramp-archive-test11-copy-file) | ||
| 523 | |||
| 478 | (ert-deftest tramp-archive-test15-copy-directory () | 524 | (ert-deftest tramp-archive-test15-copy-directory () |
| 479 | "Check `copy-directory'." | 525 | "Check `copy-directory'." |
| 480 | :tags '(:expensive-test) | 526 | :tags '(:expensive-test) |
| @@ -528,6 +574,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 528 | (ignore-errors (tramp-archive--test-delete tmp-name2)) | 574 | (ignore-errors (tramp-archive--test-delete tmp-name2)) |
| 529 | (tramp-archive-cleanup-hash)))) | 575 | (tramp-archive-cleanup-hash)))) |
| 530 | 576 | ||
| 577 | (tramp-archive--test-deftest-cascaded tramp-archive-test15-copy-directory) | ||
| 578 | |||
| 531 | (ert-deftest tramp-archive-test16-directory-files () | 579 | (ert-deftest tramp-archive-test16-directory-files () |
| 532 | "Check `directory-files'." | 580 | "Check `directory-files'." |
| 533 | :tags '(:expensive-test) | 581 | :tags '(:expensive-test) |
| @@ -552,6 +600,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 552 | ;; Cleanup. | 600 | ;; Cleanup. |
| 553 | (tramp-archive-cleanup-hash)))) | 601 | (tramp-archive-cleanup-hash)))) |
| 554 | 602 | ||
| 603 | (tramp-archive--test-deftest-cascaded tramp-archive-test16-directory-files) | ||
| 604 | |||
| 555 | (ert-deftest tramp-archive-test17-insert-directory () | 605 | (ert-deftest tramp-archive-test17-insert-directory () |
| 556 | "Check `insert-directory'." | 606 | "Check `insert-directory'." |
| 557 | :tags '(:expensive-test) | 607 | :tags '(:expensive-test) |
| @@ -600,6 +650,8 @@ This checks also `file-name-as-directory', `file-name-directory', | |||
| 600 | ;; Cleanup. | 650 | ;; Cleanup. |
| 601 | (tramp-archive-cleanup-hash)))) | 651 | (tramp-archive-cleanup-hash)))) |
| 602 | 652 | ||
| 653 | (tramp-archive--test-deftest-cascaded tramp-archive-test17-insert-directory) | ||
| 654 | |||
| 603 | (ert-deftest tramp-archive-test18-file-attributes () | 655 | (ert-deftest tramp-archive-test18-file-attributes () |
| 604 | "Check `file-attributes'. | 656 | "Check `file-attributes'. |
| 605 | This tests also `access-file', `file-readable-p' and `file-regular-p'." | 657 | This tests also `access-file', `file-readable-p' and `file-regular-p'." |
| @@ -661,6 +713,8 @@ This tests also `access-file', `file-readable-p' and `file-regular-p'." | |||
| 661 | ;; Cleanup. | 713 | ;; Cleanup. |
| 662 | (tramp-archive-cleanup-hash)))) | 714 | (tramp-archive-cleanup-hash)))) |
| 663 | 715 | ||
| 716 | (tramp-archive--test-deftest-cascaded tramp-archive-test18-file-attributes) | ||
| 717 | |||
| 664 | (ert-deftest tramp-archive-test19-directory-files-and-attributes () | 718 | (ert-deftest tramp-archive-test19-directory-files-and-attributes () |
| 665 | "Check `directory-files-and-attributes'." | 719 | "Check `directory-files-and-attributes'." |
| 666 | :tags '(:expensive-test) | 720 | :tags '(:expensive-test) |
| @@ -686,6 +740,9 @@ This tests also `access-file', `file-readable-p' and `file-regular-p'." | |||
| 686 | ;; Cleanup. | 740 | ;; Cleanup. |
| 687 | (tramp-archive-cleanup-hash)))) | 741 | (tramp-archive-cleanup-hash)))) |
| 688 | 742 | ||
| 743 | (tramp-archive--test-deftest-cascaded | ||
| 744 | tramp-archive-test19-directory-files-and-attributes) | ||
| 745 | |||
| 689 | (ert-deftest tramp-archive-test20-file-modes () | 746 | (ert-deftest tramp-archive-test20-file-modes () |
| 690 | "Check `file-modes'. | 747 | "Check `file-modes'. |
| 691 | This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | 748 | This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." |
| @@ -717,6 +774,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 717 | ;; Cleanup. | 774 | ;; Cleanup. |
| 718 | (tramp-archive-cleanup-hash)))) | 775 | (tramp-archive-cleanup-hash)))) |
| 719 | 776 | ||
| 777 | (tramp-archive--test-deftest-cascaded tramp-archive-test20-file-modes) | ||
| 778 | |||
| 720 | (ert-deftest tramp-archive-test21-file-links () | 779 | (ert-deftest tramp-archive-test21-file-links () |
| 721 | "Check `file-symlink-p' and `file-truename'" | 780 | "Check `file-symlink-p' and `file-truename'" |
| 722 | :tags '(:expensive-test) | 781 | :tags '(:expensive-test) |
| @@ -758,6 +817,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 758 | ;; Cleanup. | 817 | ;; Cleanup. |
| 759 | (tramp-archive-cleanup-hash)))) | 818 | (tramp-archive-cleanup-hash)))) |
| 760 | 819 | ||
| 820 | (tramp-archive--test-deftest-cascaded tramp-archive-test21-file-links) | ||
| 821 | |||
| 761 | (ert-deftest tramp-archive-test26-file-name-completion () | 822 | (ert-deftest tramp-archive-test26-file-name-completion () |
| 762 | "Check `file-name-completion' and `file-name-all-completions'." | 823 | "Check `file-name-completion' and `file-name-all-completions'." |
| 763 | :tags '(:expensive-test) | 824 | :tags '(:expensive-test) |
| @@ -797,6 +858,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 797 | ;; Cleanup. | 858 | ;; Cleanup. |
| 798 | (tramp-archive-cleanup-hash)))) | 859 | (tramp-archive-cleanup-hash)))) |
| 799 | 860 | ||
| 861 | (tramp-archive--test-deftest-cascaded tramp-archive-test26-file-name-completion) | ||
| 862 | |||
| 800 | (ert-deftest tramp-archive-test40-make-nearby-temp-file () | 863 | (ert-deftest tramp-archive-test40-make-nearby-temp-file () |
| 801 | "Check `make-nearby-temp-file' and `temporary-file-directory'." | 864 | "Check `make-nearby-temp-file' and `temporary-file-directory'." |
| 802 | (skip-unless tramp-archive-enabled) | 865 | (skip-unless tramp-archive-enabled) |
| @@ -824,6 +887,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 824 | (delete-directory tmp-file) | 887 | (delete-directory tmp-file) |
| 825 | (should-not (file-exists-p tmp-file)))) | 888 | (should-not (file-exists-p tmp-file)))) |
| 826 | 889 | ||
| 890 | (tramp-archive--test-deftest-cascaded tramp-archive-test40-make-nearby-temp-file) | ||
| 891 | |||
| 827 | (ert-deftest tramp-archive-test43-file-system-info () | 892 | (ert-deftest tramp-archive-test43-file-system-info () |
| 828 | "Check that `file-system-info' returns proper values." | 893 | "Check that `file-system-info' returns proper values." |
| 829 | (skip-unless tramp-archive-enabled) | 894 | (skip-unless tramp-archive-enabled) |
| @@ -837,6 +902,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 837 | (zerop (nth 1 fsi)) | 902 | (zerop (nth 1 fsi)) |
| 838 | (zerop (nth 2 fsi)))))) | 903 | (zerop (nth 2 fsi)))))) |
| 839 | 904 | ||
| 905 | (tramp-archive--test-deftest-cascaded tramp-archive-test43-file-system-info) | ||
| 906 | |||
| 840 | ;; `file-user-uid' and `file-group-gid' were introduced in Emacs 30.1. | 907 | ;; `file-user-uid' and `file-group-gid' were introduced in Emacs 30.1. |
| 841 | (ert-deftest tramp-archive-test44-user-group-ids () | 908 | (ert-deftest tramp-archive-test44-user-group-ids () |
| 842 | "Check results of user/group functions. | 909 | "Check results of user/group functions. |
| @@ -856,6 +923,8 @@ This tests also `file-executable-p', `file-writable-p' and `set-file-modes'." | |||
| 856 | (should (equal uid (with-no-warnings (file-user-uid)))) | 923 | (should (equal uid (with-no-warnings (file-user-uid)))) |
| 857 | (should (equal gid (with-no-warnings (file-group-gid))))))) | 924 | (should (equal gid (with-no-warnings (file-group-gid))))))) |
| 858 | 925 | ||
| 926 | (tramp-archive--test-deftest-cascaded tramp-archive-test44-user-group-ids) | ||
| 927 | |||
| 859 | (ert-deftest tramp-archive-test50-auto-load () | 928 | (ert-deftest tramp-archive-test50-auto-load () |
| 860 | "Check that `tramp-archive' autoloads properly." | 929 | "Check that `tramp-archive' autoloads properly." |
| 861 | :tags '(:expensive-test) | 930 | :tags '(:expensive-test) |