]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Update regular expression for testing media size names.
authorMichael R Sweet <msweet@msweet.org>
Sat, 15 Nov 2025 21:50:24 +0000 (16:50 -0500)
committerMichael R Sweet <msweet@msweet.org>
Sun, 16 Nov 2025 14:05:51 +0000 (09:05 -0500)
examples/ipp-2.0.test

index 93b4834530fa59852953c22968c983875e5a6021..337456a8f8da79b711769731619c82706d6855af 100644 (file)
@@ -1,7 +1,7 @@
 #
 # IPP/2.0 test suite.
 #
-# Copyright © 2020-2024 by OpenPrinting.
+# Copyright © 2020-2025 by OpenPrinting.
 # Copyright © 2007-2017 by Apple Inc.
 # Copyright © 2001-2006 by Easy Software Products. All rights reserved.
 #
@@ -20,8 +20,7 @@ INCLUDE "ipp-1.1.test"
 
 
 # Regular expression for PWG media size names (eek!)
-DEFINE MEDIA_REGEX "/^(choice(_((custom|na|asme|roc|oe|roll)_[a-z0-9][-a-z0-9]*_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])in|(custom|iso|jis|jpn|prc|om|roll)_[a-z0-9][-a-z0-9]*_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])mm)){2,}|(custom|na|asme|roc|oe|roll)_[a-z0-9][-a-z0-9]*_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])in|(custom|iso|jis|jpn|prc|om|roll)_[a-z0-9][-a-z0-9]*_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])mm)$$/"
-
+DEFINE MEDIA_REGEX "/^(((custom|na|asme|roc|oe|roll)_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x(([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])|0)in|(custom|iso|jis|jpn|prc|om|roll)_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x(([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])|0)mm|disc_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])mm)|choice(_((custom|na|asme|roc|oe|roll)_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x(([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])|0)in|(custom|iso|jis|jpn|prc|om|roll)_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x(([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])|0)mm|disc_([A-Za-z0-9][-A-Z.a-z0-9]*)_([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])x([1-9][0-9]*(\.[0-9]*[1-9])?|0\.[0-9]*[1-9])mm)){2,})$$/"
 
 # Test required printer description attribute support.
 #