diff options
| author | Noam Postavsky | 2019-06-25 22:04:13 -0400 |
|---|---|---|
| committer | Noam Postavsky | 2019-06-25 22:04:13 -0400 |
| commit | 9552ee4df7d2ceebb8728a61d00598aa981b580c (patch) | |
| tree | 5bd393a52f3f1b0510ff77fb2bd38e4a2c00ad8c | |
| parent | c7a59d87b5726725cffa51a1f432f0961548dbe3 (diff) | |
| parent | e62ad04963982ea9cc7622b32484778845bc2ec1 (diff) | |
| download | emacs-9552ee4df7d2ceebb8728a61d00598aa981b580c.tar.gz emacs-9552ee4df7d2ceebb8728a61d00598aa981b580c.zip | |
Merge from emacs-26
e62ad04963 Fix sgml-mode handling of quotes within parens (Bug#36347)
06b35b2f92 ; * lisp/frame.el: Enhance add-variable-watcher commentary.
572e34bb6f Rename 'make-symbolic-link' argument NEWNAME to LINKNAME
04477adedc Check that length of data returned by sysctl is non-zero
81535eeadb * test/lisp/progmodes/python-tests.el (python-virt-bin): D...
9d48979ca8 Fix Python tests depending on system-type
fcf6cc3177 Fix problem with wdired test when symlinks cannot be created.
4701e0663e Improve wording of documentation of click events
# Conflicts:
# lisp/textmodes/sgml-mode.el
# test/lisp/textmodes/sgml-mode-tests.el
| -rw-r--r-- | doc/lispref/commands.texi | 70 | ||||
| -rw-r--r-- | doc/lispref/files.texi | 8 | ||||
| -rw-r--r-- | lisp/frame.el | 4 | ||||
| -rw-r--r-- | lisp/textmodes/sgml-mode.el | 1 | ||||
| -rw-r--r-- | src/fileio.c | 10 | ||||
| -rw-r--r-- | src/filelock.c | 2 | ||||
| -rw-r--r-- | src/sysdep.c | 10 | ||||
| -rw-r--r-- | test/lisp/progmodes/python-tests.el | 20 | ||||
| -rw-r--r-- | test/lisp/textmodes/sgml-mode-tests.el | 2 | ||||
| -rw-r--r-- | test/lisp/wdired-tests.el | 6 |
10 files changed, 78 insertions, 55 deletions
diff --git a/doc/lispref/commands.texi b/doc/lispref/commands.texi index 5ea0be2667b..c0df944f9ce 100644 --- a/doc/lispref/commands.texi +++ b/doc/lispref/commands.texi | |||
| @@ -1392,9 +1392,9 @@ The time at which the event occurred, as an integer number of | |||
| 1392 | milliseconds since a system-dependent initial time. | 1392 | milliseconds since a system-dependent initial time. |
| 1393 | 1393 | ||
| 1394 | @item @var{object} | 1394 | @item @var{object} |
| 1395 | Either @code{nil} if there is no string-type text property at the | 1395 | Either @code{nil}, which means the click occurred on buffer text, or a |
| 1396 | click position, or a cons cell of the form (@var{string} | 1396 | cons cell of the form @w{(@var{string} . @var{string-pos})} if there |
| 1397 | . @var{string-pos}) if there is one: | 1397 | is a string from a text property or an overlay at the click position. |
| 1398 | 1398 | ||
| 1399 | @table @asis | 1399 | @table @asis |
| 1400 | @item @var{string} | 1400 | @item @var{string} |
| @@ -1425,15 +1425,15 @@ clicks on margins, @var{col} is measured from the left edge of the | |||
| 1425 | margin area and @var{row} is measured from the top of the margin area. | 1425 | margin area and @var{row} is measured from the top of the margin area. |
| 1426 | 1426 | ||
| 1427 | @item @var{image} | 1427 | @item @var{image} |
| 1428 | This is the image object on which the click occurred. It is either | 1428 | If there is an image at the click location, this is the image object |
| 1429 | @code{nil} if there is no image at the position clicked on, or it is | 1429 | as returned by @code{find-image} (@pxref{Defining Images}); otherwise |
| 1430 | an image object as returned by @code{find-image} if click was in an image. | 1430 | this is @code{nil}. |
| 1431 | 1431 | ||
| 1432 | @item @var{dx}, @var{dy} | 1432 | @item @var{dx}, @var{dy} |
| 1433 | These are the pixel coordinates of the click, relative to | 1433 | These are the pixel coordinates of the click, relative to the top left |
| 1434 | the top left corner of @var{object}, which is @code{(0 . 0)}. If | 1434 | corner of @var{object}, which is @code{(0 . 0)}. If @var{object} is |
| 1435 | @var{object} is @code{nil}, the coordinates are relative to the top | 1435 | @code{nil}, which stands for a buffer, the coordinates are relative to |
| 1436 | left corner of the character glyph clicked on. | 1436 | the top left corner of the character glyph clicked on. |
| 1437 | 1437 | ||
| 1438 | @item @var{width}, @var{height} | 1438 | @item @var{width}, @var{height} |
| 1439 | These are the pixel width and height of @var{object} or, if this is | 1439 | These are the pixel width and height of @var{object} or, if this is |
| @@ -2035,8 +2035,8 @@ position such events have. | |||
| 2035 | 2035 | ||
| 2036 | @defun posnp object | 2036 | @defun posnp object |
| 2037 | This function returns non-@code{nil} if @var{object} is a mouse | 2037 | This function returns non-@code{nil} if @var{object} is a mouse |
| 2038 | position list, in either of the formats documented in @ref{Click | 2038 | position list, in the format documented in @ref{Click Events}); and |
| 2039 | Events}); and @code{nil} otherwise. | 2039 | @code{nil} otherwise. |
| 2040 | @end defun | 2040 | @end defun |
| 2041 | 2041 | ||
| 2042 | @cindex mouse position list, accessing | 2042 | @cindex mouse position list, accessing |
| @@ -2064,8 +2064,8 @@ is undefined. | |||
| 2064 | 2064 | ||
| 2065 | @defun posn-x-y position | 2065 | @defun posn-x-y position |
| 2066 | Return the pixel-based x and y coordinates in @var{position}, as a | 2066 | Return the pixel-based x and y coordinates in @var{position}, as a |
| 2067 | cons cell @code{(@var{x} . @var{y})}. These coordinates are relative | 2067 | cons cell @w{@code{(@var{x} . @var{y})}}. These coordinates are |
| 2068 | to the window given by @code{posn-window}. | 2068 | relative to the window given by @code{posn-window}. |
| 2069 | 2069 | ||
| 2070 | This example shows how to convert the window-relative coordinates in | 2070 | This example shows how to convert the window-relative coordinates in |
| 2071 | the text area of a window into frame-relative coordinates: | 2071 | the text area of a window into frame-relative coordinates: |
| @@ -2083,11 +2083,11 @@ POSITION is assumed to lie in a window text area." | |||
| 2083 | @end defun | 2083 | @end defun |
| 2084 | 2084 | ||
| 2085 | @defun posn-col-row position | 2085 | @defun posn-col-row position |
| 2086 | This function returns a cons cell @code{(@var{col} . @var{row})}, | 2086 | This function returns a cons cell @w{@code{(@var{col} . @var{row})}}, |
| 2087 | containing the estimated column and row corresponding to buffer | 2087 | containing the estimated column and row corresponding to buffer |
| 2088 | position in @var{position}. The return value is given in units of the | 2088 | position described by @var{position}. The return value is given in |
| 2089 | frame's default character width and default line height (including | 2089 | units of the frame's default character width and default line height |
| 2090 | spacing), as computed from the @var{x} and @var{y} values | 2090 | (including spacing), as computed from the @var{x} and @var{y} values |
| 2091 | corresponding to @var{position}. (So, if the actual characters have | 2091 | corresponding to @var{position}. (So, if the actual characters have |
| 2092 | non-default sizes, the actual row and column may differ from these | 2092 | non-default sizes, the actual row and column may differ from these |
| 2093 | computed values.) | 2093 | computed values.) |
| @@ -2099,7 +2099,7 @@ Lines}), it is @emph{not} included in the @var{row} count. | |||
| 2099 | 2099 | ||
| 2100 | @defun posn-actual-col-row position | 2100 | @defun posn-actual-col-row position |
| 2101 | Return the actual row and column in @var{position}, as a cons cell | 2101 | Return the actual row and column in @var{position}, as a cons cell |
| 2102 | @code{(@var{col} . @var{row})}. The values are the actual row and | 2102 | @w{@code{(@var{col} . @var{row})}}. The values are the actual row and |
| 2103 | column numbers in the window given by @var{position}. @xref{Click | 2103 | column numbers in the window given by @var{position}. @xref{Click |
| 2104 | Events}, for details. The function returns @code{nil} if | 2104 | Events}, for details. The function returns @code{nil} if |
| 2105 | @var{position} does not include actual position values; in that case | 2105 | @var{position} does not include actual position values; in that case |
| @@ -2112,33 +2112,37 @@ character units, use @code{posn-col-row} instead. | |||
| 2112 | @end defun | 2112 | @end defun |
| 2113 | 2113 | ||
| 2114 | @defun posn-string position | 2114 | @defun posn-string position |
| 2115 | Return the string object in @var{position}, either @code{nil}, or a | 2115 | Return the string object described by @var{position}, either |
| 2116 | cons cell @code{(@var{string} . @var{string-pos})}. | 2116 | @code{nil} (which means @var{position} describes buffer text), or a |
| 2117 | cons cell @w{@code{(@var{string} . @var{string-pos})}}. | ||
| 2117 | @end defun | 2118 | @end defun |
| 2118 | 2119 | ||
| 2119 | @defun posn-image position | 2120 | @defun posn-image position |
| 2120 | Return the image object in @var{position}, either @code{nil}, or an | 2121 | Return the image object in @var{position}, either @code{nil} (if |
| 2121 | image @code{(image ...)}. | 2122 | there's no image at @var{position}), or an image spec @w{@code{(image |
| 2123 | @dots{})}}. | ||
| 2122 | @end defun | 2124 | @end defun |
| 2123 | 2125 | ||
| 2124 | @defun posn-object position | 2126 | @defun posn-object position |
| 2125 | Return the image or string object in @var{position}, either | 2127 | Return the image or string object described by @var{position}, either |
| 2126 | @code{nil}, an image @code{(image ...)}, or a cons cell | 2128 | @code{nil} (which means @var{position} describes buffer text), an |
| 2127 | @code{(@var{string} . @var{string-pos})}. | 2129 | image @w{@code{(image @dots{})}}, or a cons cell |
| 2130 | @w{@code{(@var{string} . @var{string-pos})}}. | ||
| 2128 | @end defun | 2131 | @end defun |
| 2129 | 2132 | ||
| 2130 | @defun posn-object-x-y position | 2133 | @defun posn-object-x-y position |
| 2131 | Return the pixel-based x and y coordinates relative to the upper left | 2134 | Return the pixel-based x and y coordinates relative to the upper left |
| 2132 | corner of the object in @var{position} as a cons cell @code{(@var{dx} | 2135 | corner of the object described by @var{position}, as a cons cell |
| 2133 | . @var{dy})}. If the @var{position} is on buffer text, return the | 2136 | @w{@code{(@var{dx} . @var{dy})}}. If the @var{position} describes |
| 2134 | relative position of the buffer-text character closest to that | 2137 | buffer text, return the relative coordinates of the buffer-text character |
| 2135 | position. | 2138 | closest to that position. |
| 2136 | @end defun | 2139 | @end defun |
| 2137 | 2140 | ||
| 2138 | @defun posn-object-width-height position | 2141 | @defun posn-object-width-height position |
| 2139 | Return the pixel width and height of the object in @var{position} as a | 2142 | Return the pixel width and height of the object described by |
| 2140 | cons cell @code{(@var{width} . @var{height})}. If the @var{position} | 2143 | @var{position}, as a cons cell @code{(@var{width} . @var{height})}. |
| 2141 | is a buffer position, return the size of the character at that position. | 2144 | If the @var{position} describes a buffer position, return the size of |
| 2145 | the character at that position. | ||
| 2142 | @end defun | 2146 | @end defun |
| 2143 | 2147 | ||
| 2144 | @cindex timestamp of a mouse event | 2148 | @cindex timestamp of a mouse event |
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi index af16b1cf4bc..66678d33915 100644 --- a/doc/lispref/files.texi +++ b/doc/lispref/files.texi | |||
| @@ -1752,12 +1752,12 @@ default file permissions (see @code{set-default-file-modes} below), if | |||
| 1752 | SELinux context are not copied over in either case. | 1752 | SELinux context are not copied over in either case. |
| 1753 | @end deffn | 1753 | @end deffn |
| 1754 | 1754 | ||
| 1755 | @deffn Command make-symbolic-link target newname &optional ok-if-already-exists | 1755 | @deffn Command make-symbolic-link target linkname &optional ok-if-already-exists |
| 1756 | @pindex ln | 1756 | @pindex ln |
| 1757 | @kindex file-already-exists | 1757 | @kindex file-already-exists |
| 1758 | This command makes a symbolic link to @var{target}, named | 1758 | This command makes a symbolic link to @var{target}, named |
| 1759 | @var{newname}. This is like the shell command @samp{ln -s | 1759 | @var{linkname}. This is like the shell command @samp{ln -s |
| 1760 | @var{target} @var{newname}}. The @var{target} argument | 1760 | @var{target} @var{linkname}}. The @var{target} argument |
| 1761 | is treated only as a string; it need not name an existing file. | 1761 | is treated only as a string; it need not name an existing file. |
| 1762 | If @var{ok-if-already-exists} is an integer, indicating interactive | 1762 | If @var{ok-if-already-exists} is an integer, indicating interactive |
| 1763 | use, then leading @samp{~} is expanded and leading @samp{/:} is | 1763 | use, then leading @samp{~} is expanded and leading @samp{/:} is |
| @@ -1767,7 +1767,7 @@ If @var{target} is a relative file name, the resulting symbolic link | |||
| 1767 | is interpreted relative to the directory containing the symbolic link. | 1767 | is interpreted relative to the directory containing the symbolic link. |
| 1768 | @xref{Relative File Names}. | 1768 | @xref{Relative File Names}. |
| 1769 | 1769 | ||
| 1770 | If both @var{target} and @var{newname} have remote file name syntax, | 1770 | If both @var{target} and @var{linkname} have remote file name syntax, |
| 1771 | and if both remote identifications are equal, the symbolic link points | 1771 | and if both remote identifications are equal, the symbolic link points |
| 1772 | to the local file name part of @var{target}. | 1772 | to the local file name part of @var{target}. |
| 1773 | 1773 | ||
diff --git a/lisp/frame.el b/lisp/frame.el index 7b61003c9ac..9402c15a56b 100644 --- a/lisp/frame.el +++ b/lisp/frame.el | |||
| @@ -2672,7 +2672,9 @@ See also `toggle-frame-maximized'." | |||
| 2672 | (mapc (lambda (var) | 2672 | (mapc (lambda (var) |
| 2673 | ;; Using symbol-function here tells the watcher machinery to | 2673 | ;; Using symbol-function here tells the watcher machinery to |
| 2674 | ;; call the C function set-buffer-redisplay directly, thus | 2674 | ;; call the C function set-buffer-redisplay directly, thus |
| 2675 | ;; avoiding a potential GC. | 2675 | ;; avoiding a potential GC. This isn't strictly necessary, |
| 2676 | ;; but it's a nice way to exercise the direct subr-calling | ||
| 2677 | ;; machinery. | ||
| 2676 | (add-variable-watcher var (symbol-function 'set-buffer-redisplay))) | 2678 | (add-variable-watcher var (symbol-function 'set-buffer-redisplay))) |
| 2677 | '(line-spacing | 2679 | '(line-spacing |
| 2678 | overline-margin | 2680 | overline-margin |
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index 8d3000e5d8b..aa00024a6d9 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el | |||
| @@ -614,6 +614,7 @@ Do \\[describe-key] on the following bindings to discover what they do. | |||
| 614 | (font-lock-syntactic-face-function | 614 | (font-lock-syntactic-face-function |
| 615 | . sgml-font-lock-syntactic-face))) | 615 | . sgml-font-lock-syntactic-face))) |
| 616 | (setq-local syntax-propertize-function #'sgml-syntax-propertize) | 616 | (setq-local syntax-propertize-function #'sgml-syntax-propertize) |
| 617 | (setq-local syntax-ppss-table sgml-tag-syntax-table) | ||
| 617 | (setq-local facemenu-add-face-function 'sgml-mode-facemenu-add-face-function) | 618 | (setq-local facemenu-add-face-function 'sgml-mode-facemenu-add-face-function) |
| 618 | (setq-local sgml-xml-mode (sgml-xml-guess)) | 619 | (setq-local sgml-xml-mode (sgml-xml-guess)) |
| 619 | (unless sgml-xml-mode | 620 | (unless sgml-xml-mode |
diff --git a/src/fileio.c b/src/fileio.c index 5dd14daacb4..0da9894a73a 100644 --- a/src/fileio.c +++ b/src/fileio.c | |||
| @@ -2599,13 +2599,13 @@ This is what happens in interactive use with M-x. */) | |||
| 2599 | 2599 | ||
| 2600 | DEFUN ("make-symbolic-link", Fmake_symbolic_link, Smake_symbolic_link, 2, 3, | 2600 | DEFUN ("make-symbolic-link", Fmake_symbolic_link, Smake_symbolic_link, 2, 3, |
| 2601 | "FMake symbolic link to file: \nGMake symbolic link to file %s: \np", | 2601 | "FMake symbolic link to file: \nGMake symbolic link to file %s: \np", |
| 2602 | doc: /* Make a symbolic link to TARGET, named NEWNAME. | 2602 | doc: /* Make a symbolic link to TARGET, named LINKNAME. |
| 2603 | If NEWNAME is a directory name, make a like-named symbolic link under | 2603 | If LINKNAME is a directory name, make a like-named symbolic link under |
| 2604 | NEWNAME. | 2604 | LINKNAME. |
| 2605 | 2605 | ||
| 2606 | Signal a `file-already-exists' error if a file NEWNAME already exists | 2606 | Signal a `file-already-exists' error if a file LINKNAME already exists |
| 2607 | unless optional third argument OK-IF-ALREADY-EXISTS is non-nil. | 2607 | unless optional third argument OK-IF-ALREADY-EXISTS is non-nil. |
| 2608 | An integer third arg means request confirmation if NEWNAME already | 2608 | An integer third arg means request confirmation if LINKNAME already |
| 2609 | exists, and expand leading "~" or strip leading "/:" in TARGET. | 2609 | exists, and expand leading "~" or strip leading "/:" in TARGET. |
| 2610 | This happens for interactive use with M-x. */) | 2610 | This happens for interactive use with M-x. */) |
| 2611 | (Lisp_Object target, Lisp_Object linkname, Lisp_Object ok_if_already_exists) | 2611 | (Lisp_Object target, Lisp_Object linkname, Lisp_Object ok_if_already_exists) |
diff --git a/src/filelock.c b/src/filelock.c index baf87b7f635..b1f7d9dce61 100644 --- a/src/filelock.c +++ b/src/filelock.c | |||
| @@ -152,7 +152,7 @@ get_boot_time (void) | |||
| 152 | mib[1] = KERN_BOOTTIME; | 152 | mib[1] = KERN_BOOTTIME; |
| 153 | size = sizeof (boottime_val); | 153 | size = sizeof (boottime_val); |
| 154 | 154 | ||
| 155 | if (sysctl (mib, 2, &boottime_val, &size, NULL, 0) >= 0) | 155 | if (sysctl (mib, 2, &boottime_val, &size, NULL, 0) >= 0 && size != 0) |
| 156 | { | 156 | { |
| 157 | boot_time = boottime_val.tv_sec; | 157 | boot_time = boottime_val.tv_sec; |
| 158 | return boot_time; | 158 | return boot_time; |
diff --git a/src/sysdep.c b/src/sysdep.c index f7fc99f147f..4f89e8aba10 100644 --- a/src/sysdep.c +++ b/src/sysdep.c | |||
| @@ -3018,11 +3018,11 @@ list_system_processes (void) | |||
| 3018 | 3018 | ||
| 3019 | Lisp_Object proclist = Qnil; | 3019 | Lisp_Object proclist = Qnil; |
| 3020 | 3020 | ||
| 3021 | if (sysctl (mib, 3, NULL, &len, NULL, 0) != 0) | 3021 | if (sysctl (mib, 3, NULL, &len, NULL, 0) != 0 || len == 0) |
| 3022 | return proclist; | 3022 | return proclist; |
| 3023 | 3023 | ||
| 3024 | procs = xmalloc (len); | 3024 | procs = xmalloc (len); |
| 3025 | if (sysctl (mib, 3, procs, &len, NULL, 0) != 0) | 3025 | if (sysctl (mib, 3, procs, &len, NULL, 0) != 0 || len == 0) |
| 3026 | { | 3026 | { |
| 3027 | xfree (procs); | 3027 | xfree (procs); |
| 3028 | return proclist; | 3028 | return proclist; |
| @@ -3616,7 +3616,7 @@ system_process_attributes (Lisp_Object pid) | |||
| 3616 | CONS_TO_INTEGER (pid, int, proc_id); | 3616 | CONS_TO_INTEGER (pid, int, proc_id); |
| 3617 | mib[3] = proc_id; | 3617 | mib[3] = proc_id; |
| 3618 | 3618 | ||
| 3619 | if (sysctl (mib, 4, &proc, &proclen, NULL, 0) != 0) | 3619 | if (sysctl (mib, 4, &proc, &proclen, NULL, 0) != 0 || proclen == 0) |
| 3620 | return attrs; | 3620 | return attrs; |
| 3621 | 3621 | ||
| 3622 | attrs = Fcons (Fcons (Qeuid, INT_TO_INTEGER (proc.ki_uid)), attrs); | 3622 | attrs = Fcons (Fcons (Qeuid, INT_TO_INTEGER (proc.ki_uid)), attrs); |
| @@ -3739,7 +3739,7 @@ system_process_attributes (Lisp_Object pid) | |||
| 3739 | 3739 | ||
| 3740 | mib[2] = KERN_PROC_ARGS; | 3740 | mib[2] = KERN_PROC_ARGS; |
| 3741 | len = MAXPATHLEN; | 3741 | len = MAXPATHLEN; |
| 3742 | if (sysctl (mib, 4, args, &len, NULL, 0) == 0) | 3742 | if (sysctl (mib, 4, args, &len, NULL, 0) == 0 && len != 0) |
| 3743 | { | 3743 | { |
| 3744 | int i; | 3744 | int i; |
| 3745 | for (i = 0; i < len; i++) | 3745 | for (i = 0; i < len; i++) |
| @@ -3785,7 +3785,7 @@ system_process_attributes (Lisp_Object pid) | |||
| 3785 | CONS_TO_INTEGER (pid, int, proc_id); | 3785 | CONS_TO_INTEGER (pid, int, proc_id); |
| 3786 | mib[3] = proc_id; | 3786 | mib[3] = proc_id; |
| 3787 | 3787 | ||
| 3788 | if (sysctl (mib, 4, &proc, &proclen, NULL, 0) != 0) | 3788 | if (sysctl (mib, 4, &proc, &proclen, NULL, 0) != 0 || proclen == 0) |
| 3789 | return attrs; | 3789 | return attrs; |
| 3790 | 3790 | ||
| 3791 | uid = proc.kp_eproc.e_ucred.cr_uid; | 3791 | uid = proc.kp_eproc.e_ucred.cr_uid; |
diff --git a/test/lisp/progmodes/python-tests.el b/test/lisp/progmodes/python-tests.el index 87cee189eac..b1cf7e8806a 100644 --- a/test/lisp/progmodes/python-tests.el +++ b/test/lisp/progmodes/python-tests.el | |||
| @@ -134,6 +134,16 @@ default to `point-min' and `point-max' respectively." | |||
| 134 | (overlay-end overlay)))) | 134 | (overlay-end overlay)))) |
| 135 | (buffer-substring-no-properties (point-min) (point-max))))) | 135 | (buffer-substring-no-properties (point-min) (point-max))))) |
| 136 | 136 | ||
| 137 | (defun python-virt-bin (&optional virt-root) | ||
| 138 | "Return the virtualenv bin dir, starting from VIRT-ROOT. | ||
| 139 | If nil, VIRT-ROOT defaults to `python-shell-virtualenv-root'. | ||
| 140 | The name of this directory depends on `system-type'." | ||
| 141 | (expand-file-name | ||
| 142 | (concat | ||
| 143 | (file-name-as-directory (or virt-root | ||
| 144 | python-shell-virtualenv-root)) | ||
| 145 | (if (eq system-type 'windows-nt) "Scripts" "bin")))) | ||
| 146 | |||
| 137 | 147 | ||
| 138 | ;;; Tests for your tests, so you can test while you test. | 148 | ;;; Tests for your tests, so you can test while you test. |
| 139 | 149 | ||
| @@ -2704,7 +2714,7 @@ if x: | |||
| 2704 | (python-shell-virtualenv-root "/env") | 2714 | (python-shell-virtualenv-root "/env") |
| 2705 | (new-exec-path (python-shell-calculate-exec-path))) | 2715 | (new-exec-path (python-shell-calculate-exec-path))) |
| 2706 | (should (equal new-exec-path | 2716 | (should (equal new-exec-path |
| 2707 | (list (expand-file-name "/env/bin") "/path0"))))) | 2717 | (list (python-virt-bin) "/path0"))))) |
| 2708 | 2718 | ||
| 2709 | (ert-deftest python-shell-calculate-exec-path-3 () | 2719 | (ert-deftest python-shell-calculate-exec-path-3 () |
| 2710 | "Test complete `python-shell-virtualenv-root' modification." | 2720 | "Test complete `python-shell-virtualenv-root' modification." |
| @@ -2713,7 +2723,7 @@ if x: | |||
| 2713 | (python-shell-virtualenv-root "/env") | 2723 | (python-shell-virtualenv-root "/env") |
| 2714 | (new-exec-path (python-shell-calculate-exec-path))) | 2724 | (new-exec-path (python-shell-calculate-exec-path))) |
| 2715 | (should (equal new-exec-path | 2725 | (should (equal new-exec-path |
| 2716 | (list (expand-file-name "/env/bin") | 2726 | (list (python-virt-bin) |
| 2717 | "/path1" "/path2" "/path0"))))) | 2727 | "/path1" "/path2" "/path0"))))) |
| 2718 | 2728 | ||
| 2719 | (ert-deftest python-shell-calculate-exec-path-4 () | 2729 | (ert-deftest python-shell-calculate-exec-path-4 () |
| @@ -2724,7 +2734,7 @@ if x: | |||
| 2724 | (python-shell-virtualenv-root "/env") | 2734 | (python-shell-virtualenv-root "/env") |
| 2725 | (new-exec-path (python-shell-calculate-exec-path))) | 2735 | (new-exec-path (python-shell-calculate-exec-path))) |
| 2726 | (should (equal new-exec-path | 2736 | (should (equal new-exec-path |
| 2727 | (list (expand-file-name "/env/bin") | 2737 | (list (python-virt-bin) |
| 2728 | "/path1" "/path2" "/path0"))))) | 2738 | "/path1" "/path2" "/path0"))))) |
| 2729 | 2739 | ||
| 2730 | (ert-deftest python-shell-calculate-exec-path-5 () | 2740 | (ert-deftest python-shell-calculate-exec-path-5 () |
| @@ -2754,7 +2764,7 @@ if x: | |||
| 2754 | (python-shell-virtualenv-root "/env")) | 2764 | (python-shell-virtualenv-root "/env")) |
| 2755 | (python-shell-with-environment | 2765 | (python-shell-with-environment |
| 2756 | (should (equal exec-path | 2766 | (should (equal exec-path |
| 2757 | (list (expand-file-name "/env/bin") | 2767 | (list (python-virt-bin) |
| 2758 | "/path1" "/path2" "/path0"))) | 2768 | "/path1" "/path2" "/path0"))) |
| 2759 | (should (not (getenv "PYTHONHOME"))) | 2769 | (should (not (getenv "PYTHONHOME"))) |
| 2760 | (should (string= (getenv "VIRTUAL_ENV") "/env"))) | 2770 | (should (string= (getenv "VIRTUAL_ENV") "/env"))) |
| @@ -2770,7 +2780,7 @@ if x: | |||
| 2770 | (python-shell-virtualenv-root "/env")) | 2780 | (python-shell-virtualenv-root "/env")) |
| 2771 | (python-shell-with-environment | 2781 | (python-shell-with-environment |
| 2772 | (should (equal (python-shell-calculate-exec-path) | 2782 | (should (equal (python-shell-calculate-exec-path) |
| 2773 | (list (expand-file-name "/env/bin") | 2783 | (list (python-virt-bin) |
| 2774 | "/path1" "/path2" "/remote1" "/remote2"))) | 2784 | "/path1" "/path2" "/remote1" "/remote2"))) |
| 2775 | (let ((process-environment (python-shell-calculate-process-environment))) | 2785 | (let ((process-environment (python-shell-calculate-process-environment))) |
| 2776 | (should (not (getenv "PYTHONHOME"))) | 2786 | (should (not (getenv "PYTHONHOME"))) |
diff --git a/test/lisp/textmodes/sgml-mode-tests.el b/test/lisp/textmodes/sgml-mode-tests.el index 34d26480a45..5630036e55c 100644 --- a/test/lisp/textmodes/sgml-mode-tests.el +++ b/test/lisp/textmodes/sgml-mode-tests.el | |||
| @@ -171,6 +171,8 @@ The point is set to the beginning of the buffer." | |||
| 171 | "<tag>c>'d</tag>" | 171 | "<tag>c>'d</tag>" |
| 172 | "<t><!-- \" --></t>" | 172 | "<t><!-- \" --></t>" |
| 173 | "<t><!-- ' --></t>" | 173 | "<t><!-- ' --></t>" |
| 174 | "<t>(')</t>" | ||
| 175 | "<t>(\")</t>" | ||
| 174 | )) | 176 | )) |
| 175 | (with-temp-buffer | 177 | (with-temp-buffer |
| 176 | (sgml-mode) | 178 | (sgml-mode) |
diff --git a/test/lisp/wdired-tests.el b/test/lisp/wdired-tests.el index 9682843db29..6db2e03e752 100644 --- a/test/lisp/wdired-tests.el +++ b/test/lisp/wdired-tests.el | |||
| @@ -86,7 +86,11 @@ only the name before the link arrow." | |||
| 86 | (let ((buf (find-file-noselect test-dir))) | 86 | (let ((buf (find-file-noselect test-dir))) |
| 87 | (unwind-protect | 87 | (unwind-protect |
| 88 | (with-current-buffer buf | 88 | (with-current-buffer buf |
| 89 | (make-symbolic-link "./bar/baz" link-name) | 89 | (skip-unless |
| 90 | ;; This check is for wdired, not symbolic links, so skip | ||
| 91 | ;; it when make-symbolic-link fails for any reason (like | ||
| 92 | ;; insufficient privileges). | ||
| 93 | (ignore-errors (make-symbolic-link "./bar/baz" link-name) t)) | ||
| 90 | (revert-buffer) | 94 | (revert-buffer) |
| 91 | (let* ((file-name (dired-get-filename)) | 95 | (let* ((file-name (dired-get-filename)) |
| 92 | (dir-part (file-name-directory file-name)) | 96 | (dir-part (file-name-directory file-name)) |