]> git.saurik.com Git - apt.git/blobdiff - test/integration/test-apt-cli-search
support regular expressions in 'apt search'
[apt.git] / test / integration / test-apt-cli-search
index 58613717b1677b5a91c0e8c9760aea7f75b2ee33..3ac0749524d3cbdb0a1a9f2ac658b158b74cc21a 100755 (executable)
@@ -33,16 +33,31 @@ foo/unstable 1.0 all
 testequal "foo/unstable 1.0 all
   $DESCR
 " apt search -qq xxyyzz
+testempty apt search -qq --names-only xxyyzz
+
+# search name
+testequal "foo/unstable 1.0 all
+  $DESCR
+" apt search -qq foo
+testequal "foo/unstable 1.0 all
+  $DESCR
+" apt search -qq --names-only foo
 
 # search with multiple words is a AND search
 testequal "foo/unstable 1.0 all
   $DESCR
 " apt search -qq aabbcc xxyyzz
+testequal "foo/unstable 1.0 all
+  $DESCR
+" apt search -qq 'a+b+c+' 'i*xxy{0,2}zz'
 
 # search is not case-sensitive by default
 testequal "foo/unstable 1.0 all
   $DESCR
 " apt search -qq uppercase
+testequal "foo/unstable 1.0 all
+  $DESCR
+" apt search -qq 'up[pP]erc[Aa]se'
 
 # output is sorted and search word finds both package
 testequal "bar/testing 2.0 i386