[latex3-commits] [git/LaTeX3-latex3-xcolor] testl3color: repair testfile (4462745)
Ulrike Fischer
fischer at troubleshooting-tex.de
Wed Aug 17 10:11:04 CEST 2022
Repository : https://github.com/latex3/xcolor
On branch : testl3color
Link : https://github.com/latex3/xcolor/commit/4462745e6a7377bc60c1e91b82f183b628f22a0b
>---------------------------------------------------------------
commit 4462745e6a7377bc60c1e91b82f183b628f22a0b
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date: Wed Aug 17 10:11:04 2022 +0200
repair testfile
>---------------------------------------------------------------
4462745e6a7377bc60c1e91b82f183b628f22a0b
testfiles/l3color-define-04.lvt | 51 +++++++++++++++++++++++++++++++++++++----
1 file changed, 47 insertions(+), 4 deletions(-)
diff --git a/testfiles/l3color-define-04.lvt b/testfiles/l3color-define-04.lvt
index e36bc0c..042cd88 100644
--- a/testfiles/l3color-define-04.lvt
+++ b/testfiles/l3color-define-04.lvt
@@ -1,17 +1,60 @@
% !Mode:: "TeX:UTF-8:Main"
+% !Mode:: "TeX:UTF-8:Main"
\DocumentMetadata{}
\input{regression-test}
\documentclass{article}
\usepackage{xcolor}
-\definespotcolor{spot}{PANTONE 3005 U}{1,0.56,0,0}
+
\begin{document}
\START
-\showoutput
+\ExplSyntaxOn\makeatletter
+% no full support for spot colors,
+% they use the cmyk fallback.
+\TEST{colorlet}
+ {
+ \colorlet{test}{red}
+ \color_export:nnN {red}{backend}\l_tmpa_tl
+ \color_export:nnN {test}{backend}\l_tmpb_tl
+ \ASSERTSTR{\l_tmpa_tl}{\l_tmpb_tl}
+ }
+
+\TEST{colorlet}
+ {
+ \colorlet{test}{red!50!blue}
+ \color_export:nnnN {rgb}{0.5,0,0.5}{backend}\l_tmpa_tl
+ \color_export:nnN {test}{backend}\l_tmpb_tl
+ \ASSERTSTR{\l_tmpa_tl}{\l_tmpb_tl}
+ }
+
+\TEST{colorlet}
+ {
+ \colorlet{test}[cmyk]{red!50!blue}
+ \color_export:nnnN {cmyk}{0,0.5,0,0.5}{backend}\l_tmpa_tl
+ \color_export:nnN {test}{backend}\l_tmpb_tl
+ \ASSERTSTR{\l_tmpa_tl}{\l_tmpb_tl}
+ }
+
+%the named + ps is only of interest in dvips, and is ignored by l3color
+\TEST{colorlet}
+ {
+ \colorlet[named]{test}{red!50!blue}
+ \color_export:nnnN {rgb}{0.5,0,0.5}{backend}\l_tmpa_tl
+ \color_export:nnN {test}{backend}\l_tmpb_tl
+ \ASSERTSTR{\l_tmpa_tl}{\l_tmpb_tl}
+ }
+
+% value is always black with l3color
+\TEST{colorlet}
+ {
+ \colorlet[ps]{test}{red!50!blue}
+ \color_export:nnnN {rgb}{1,1,1}{backend}\l_tmpa_tl
+ \color_export:nnN {test}{backend}\l_tmpb_tl
+ \ASSERTSTR{\l_tmpa_tl}{\l_tmpb_tl}
+ }
+\ExplSyntaxOff
-\color{spot} spot
-\color{red!
\OMIT
\end{document}
More information about the latex3-commits
mailing list.