diff options
author | Gabriel F. T. Gomes <gabriel@inconstante.net.br> | 2020-08-03 18:43:13 -0300 |
---|---|---|
committer | Gabriel F. T. Gomes <gabriel@inconstante.net.br> | 2020-08-03 18:43:13 -0300 |
commit | 95623d39d6029ba78ec96ad5ea08e9ac12629b91 (patch) | |
tree | ea0fe36eb5e6f40e0a1f765d44c4b0c0b2bfb089 /test/fixtures | |
parent | 019f3cc463db63abc6460f97deb488deec43840b (diff) | |
download | bash-completion-95623d39d6029ba78ec96ad5ea08e9ac12629b91.tar.gz |
New upstream version 2.11upstream/2.11upstream
Diffstat (limited to 'test/fixtures')
19 files changed, 193 insertions, 12 deletions
diff --git a/test/fixtures/_known_hosts_real/.ssh/config_asterisk_1 b/test/fixtures/_known_hosts_real/.ssh/config_asterisk_1 new file mode 100644 index 00000000..fc09eb03 --- /dev/null +++ b/test/fixtures/_known_hosts_real/.ssh/config_asterisk_1 @@ -0,0 +1 @@ +Host asterisk_1 diff --git a/test/fixtures/_known_hosts_real/.ssh/config_asterisk_2 b/test/fixtures/_known_hosts_real/.ssh/config_asterisk_2 new file mode 100644 index 00000000..42243ad2 --- /dev/null +++ b/test/fixtures/_known_hosts_real/.ssh/config_asterisk_2 @@ -0,0 +1 @@ +Host asterisk_2 diff --git a/test/fixtures/_known_hosts_real/.ssh/config_question_mark b/test/fixtures/_known_hosts_real/.ssh/config_question_mark new file mode 100644 index 00000000..08e1201f --- /dev/null +++ b/test/fixtures/_known_hosts_real/.ssh/config_question_mark @@ -0,0 +1 @@ +Host question_mark diff --git a/test/fixtures/_known_hosts_real/config b/test/fixtures/_known_hosts_real/config index 1231dd79..fe3fb54a 100644 --- a/test/fixtures/_known_hosts_real/config +++ b/test/fixtures/_known_hosts_real/config @@ -1,7 +1,7 @@ - UserKnownHostsFile fixtures/_known_hosts_real/known_hosts + UserKnownHostsFile _known_hosts_real/known_hosts # Unindented -Host gee jar +Host gee* jar?this-part-we-do-not-complete-at-least-yet HostName %h.example.com # Indented - Host hus # With comment + Host hus%%eth0 !negated #not-a-comment diff --git a/test/fixtures/_known_hosts_real/config_include b/test/fixtures/_known_hosts_real/config_include index fe6f537e..a1ae7633 100644 --- a/test/fixtures/_known_hosts_real/config_include +++ b/test/fixtures/_known_hosts_real/config_include @@ -3,3 +3,5 @@ Include ~/config_full_path # Include with relative path Include config_relative_path +# Include with wildcards, and more than one on same row +Include config_asterisk* config_?uestion_mark diff --git a/test/fixtures/_known_hosts_real/config_tilde b/test/fixtures/_known_hosts_real/config_tilde index 0893515b..4181aaf5 100644 --- a/test/fixtures/_known_hosts_real/config_tilde +++ b/test/fixtures/_known_hosts_real/config_tilde @@ -1,4 +1,4 @@ # With quotes and tilde -UserKnownHostsFile "~/fixtures/_known_hosts_real/known_hosts2" +UserKnownHostsFile "~/_known_hosts_real/known_hosts2" # Without quotes, with tilde, and another on the same line -UserKnownHostsFile ~/fixtures/_known_hosts_real/known_hosts3 fixtures/_known_hosts_real/known_hosts4 +UserKnownHostsFile ~/_known_hosts_real/known_hosts3 _known_hosts_real/known_hosts4 diff --git a/test/fixtures/slackware/etc/slapt-get/slapt-getrc b/test/fixtures/_known_hosts_real/gee-filename-canary index e69de29b..e69de29b 100644 --- a/test/fixtures/slackware/etc/slapt-get/slapt-getrc +++ b/test/fixtures/_known_hosts_real/gee-filename-canary diff --git a/test/fixtures/_known_hosts_real/localhost_config b/test/fixtures/_known_hosts_real/localhost_config index 1e751338..30b6623b 100644 --- a/test/fixtures/_known_hosts_real/localhost_config +++ b/test/fixtures/_known_hosts_real/localhost_config @@ -1 +1 @@ -UserKnownHostsFile fixtures/_known_hosts_real/localhost_hosts +UserKnownHostsFile _known_hosts_real/localhost_hosts diff --git a/test/fixtures/_known_hosts_real/spaced conf b/test/fixtures/_known_hosts_real/spaced conf index f484f0e3..566b92c2 100644 --- a/test/fixtures/_known_hosts_real/spaced conf +++ b/test/fixtures/_known_hosts_real/spaced conf @@ -1,9 +1,8 @@ # Unindented Host gee - UserKnownHostsFile "fixtures/_known_hosts_real/spaced known_hosts" + UserKnownHostsFile "_known_hosts_real/spaced known_hosts" # Indented - Host hus # With comment - UserKnownHostsFile "fixtures/_known_hosts_real/known_hosts2" - + Host hus #not-a-comment + UserKnownHostsFile "_known_hosts_real/known_hosts2" diff --git a/test/fixtures/_longopt/various.txt b/test/fixtures/_longopt/various.txt new file mode 100644 index 00000000..04c2c256 --- /dev/null +++ b/test/fixtures/_longopt/various.txt @@ -0,0 +1,5 @@ +--- +----nonono +--foo_bar +--foo- +--foo=bar diff --git a/test/fixtures/ant/.gitignore b/test/fixtures/ant/.gitignore index 459f1019..3a08258b 100644 --- a/test/fixtures/ant/.gitignore +++ b/test/fixtures/ant/.gitignore @@ -1,2 +1 @@ -.ant-targets-build.xml -.ant-targets-named-build.xml +.ant-targets-*.xml diff --git a/test/fixtures/slackware/etc/slapt-get/slapt-srcrc b/test/fixtures/dpkg/bash-completion-test-nonsubject.txt index e69de29b..e69de29b 100644 --- a/test/fixtures/slackware/etc/slapt-get/slapt-srcrc +++ b/test/fixtures/dpkg/bash-completion-test-nonsubject.txt diff --git a/test/fixtures/lftp/.lftp/bookmarks b/test/fixtures/lftp/.lftp/bookmarks index 31ec9303..074f8120 100644 --- a/test/fixtures/lftp/.lftp/bookmarks +++ b/test/fixtures/lftp/.lftp/bookmarks @@ -1 +1,3 @@ lftptest ftp://ftp.funet.fi/ +spacetest ftp://ftp.sunet.se/ +badbookmark diff --git a/test/fixtures/lilo/lilo.conf b/test/fixtures/lilo/lilo.conf new file mode 100644 index 00000000..c8901758 --- /dev/null +++ b/test/fixtures/lilo/lilo.conf @@ -0,0 +1,34 @@ +# global options: +boot=/dev/hda +prompt +timeout=150 +lba32 +compact +vga=normal +root=/dev/hda1 +read-only +menu-title=" John's Computer " +# +### bootable kernel images ### +image=/boot/vmlinuz-2.6.29-1-i386 + label=try + initrd=/boot/initrd.img-2.6.29-1-i386 +#image=/boot/vmlinuz-2.4.33-1-i386 +# label=2.4.33 +image=/tamu/vmlinuz + label=tamu + initrd=/tamu/initrd.img + root=/dev/hdb2 + vga=ask +# +### other operating systems ### +other=/dev/hda3 + label=PCDOS + boot-as=0x80 # must be C: +other=/dev/hdb1 + label=WinXP + boot-as=0x80 # must be C: +other=/dev/hdb5 + label=oldDOS + loader=chain + table=/dev/hdb5 diff --git a/test/fixtures/nmap/nmap-h.txt b/test/fixtures/nmap/nmap-h.txt new file mode 100644 index 00000000..0301d374 --- /dev/null +++ b/test/fixtures/nmap/nmap-h.txt @@ -0,0 +1,114 @@ +Nmap 7.60 ( https://nmap.org ) +Usage: nmap [Scan Type(s)] [Options] {target specification} +TARGET SPECIFICATION: + Can pass hostnames, IP addresses, networks, etc. + Ex: scanme.nmap.org, microsoft.com/24, 192.168.0.1; 10.0.0-255.1-254 + -iL <inputfilename>: Input from list of hosts/networks + -iR <num hosts>: Choose random targets + --exclude <host1[,host2][,host3],...>: Exclude hosts/networks + --excludefile <exclude_file>: Exclude list from file +HOST DISCOVERY: + -sL: List Scan - simply list targets to scan + -sn: Ping Scan - disable port scan + -Pn: Treat all hosts as online -- skip host discovery + -PS/PA/PU/PY[portlist]: TCP SYN/ACK, UDP or SCTP discovery to given ports + -PE/PP/PM: ICMP echo, timestamp, and netmask request discovery probes + -PO[protocol list]: IP Protocol Ping + -n/-R: Never do DNS resolution/Always resolve [default: sometimes] + --dns-servers <serv1[,serv2],...>: Specify custom DNS servers + --system-dns: Use OS's DNS resolver + --traceroute: Trace hop path to each host +SCAN TECHNIQUES: + -sS/sT/sA/sW/sM: TCP SYN/Connect()/ACK/Window/Maimon scans + -sU: UDP Scan + -sN/sF/sX: TCP Null, FIN, and Xmas scans + --scanflags <flags>: Customize TCP scan flags + -sI <zombie host[:probeport]>: Idle scan + -sY/sZ: SCTP INIT/COOKIE-ECHO scans + -sO: IP protocol scan + -b <FTP relay host>: FTP bounce scan +PORT SPECIFICATION AND SCAN ORDER: + -p <port ranges>: Only scan specified ports + Ex: -p22; -p1-65535; -p U:53,111,137,T:21-25,80,139,8080,S:9 + --exclude-ports <port ranges>: Exclude the specified ports from scanning + -F: Fast mode - Scan fewer ports than the default scan + -r: Scan ports consecutively - don't randomize + --top-ports <number>: Scan <number> most common ports + --port-ratio <ratio>: Scan ports more common than <ratio> +SERVICE/VERSION DETECTION: + -sV: Probe open ports to determine service/version info + --version-intensity <level>: Set from 0 (light) to 9 (try all probes) + --version-light: Limit to most likely probes (intensity 2) + --version-all: Try every single probe (intensity 9) + --version-trace: Show detailed version scan activity (for debugging) +SCRIPT SCAN: + -sC: equivalent to --script=default + --script=<Lua scripts>: <Lua scripts> is a comma separated list of + directories, script-files or script-categories + --script-args=<n1=v1,[n2=v2,...]>: provide arguments to scripts + --script-args-file=filename: provide NSE script args in a file + --script-trace: Show all data sent and received + --script-updatedb: Update the script database. + --script-help=<Lua scripts>: Show help about scripts. + <Lua scripts> is a comma-separated list of script-files or + script-categories. +OS DETECTION: + -O: Enable OS detection + --osscan-limit: Limit OS detection to promising targets + --osscan-guess: Guess OS more aggressively +TIMING AND PERFORMANCE: + Options which take <time> are in seconds, or append 'ms' (milliseconds), + 's' (seconds), 'm' (minutes), or 'h' (hours) to the value (e.g. 30m). + -T<0-5>: Set timing template (higher is faster) + --min-hostgroup/max-hostgroup <size>: Parallel host scan group sizes + --min-parallelism/max-parallelism <numprobes>: Probe parallelization + --min-rtt-timeout/max-rtt-timeout/initial-rtt-timeout <time>: Specifies + probe round trip time. + --max-retries <tries>: Caps number of port scan probe retransmissions. + --host-timeout <time>: Give up on target after this long + --scan-delay/--max-scan-delay <time>: Adjust delay between probes + --min-rate <number>: Send packets no slower than <number> per second + --max-rate <number>: Send packets no faster than <number> per second +FIREWALL/IDS EVASION AND SPOOFING: + -f; --mtu <val>: fragment packets (optionally w/given MTU) + -D <decoy1,decoy2[,ME],...>: Cloak a scan with decoys + -S <IP_Address>: Spoof source address + -e <iface>: Use specified interface + -g/--source-port <portnum>: Use given port number + --proxies <url1,[url2],...>: Relay connections through HTTP/SOCKS4 proxies + --data <hex string>: Append a custom payload to sent packets + --data-string <string>: Append a custom ASCII string to sent packets + --data-length <num>: Append random data to sent packets + --ip-options <options>: Send packets with specified ip options + --ttl <val>: Set IP time-to-live field + --spoof-mac <mac address/prefix/vendor name>: Spoof your MAC address + --badsum: Send packets with a bogus TCP/UDP/SCTP checksum +OUTPUT: + -oN/-oX/-oS/-oG <file>: Output scan in normal, XML, s|<rIpt kIddi3, + and Grepable format, respectively, to the given filename. + -oA <basename>: Output in the three major formats at once + -v: Increase verbosity level (use -vv or more for greater effect) + -d: Increase debugging level (use -dd or more for greater effect) + --reason: Display the reason a port is in a particular state + --open: Only show open (or possibly open) ports + --packet-trace: Show all packets sent and received + --iflist: Print host interfaces and routes (for debugging) + --append-output: Append to rather than clobber specified output files + --resume <filename>: Resume an aborted scan + --stylesheet <path/URL>: XSL stylesheet to transform XML output to HTML + --webxml: Reference stylesheet from Nmap.Org for more portable XML + --no-stylesheet: Prevent associating of XSL stylesheet w/XML output +MISC: + -6: Enable IPv6 scanning + -A: Enable OS detection, version detection, script scanning, and traceroute + --datadir <dirname>: Specify custom Nmap data file location + --send-eth/--send-ip: Send using raw ethernet frames or IP packets + --privileged: Assume that the user is fully privileged + --unprivileged: Assume the user lacks raw socket privileges + -V: Print version number + -h: Print this help summary page. +EXAMPLES: + nmap -v -A scanme.nmap.org + nmap -v -sn 192.168.0.0/16 10.0.0.0/8 + nmap -v -iR 10000 -Pn -p 80 +SEE THE MAN PAGE (https://nmap.org/book/man.html) FOR MORE OPTIONS AND EXAMPLES diff --git a/test/fixtures/perl/Devel/BashCompletion.pm b/test/fixtures/perl/Devel/BashCompletion.pm index 0afc6045..f8e829d8 100644 --- a/test/fixtures/perl/Devel/BashCompletion.pm +++ b/test/fixtures/perl/Devel/BashCompletion.pm @@ -1 +1,3 @@ +use strict; +use warnings; 1; diff --git a/test/fixtures/perldoc/BashCompletionModule.pm b/test/fixtures/perldoc/BashCompletionModule.pm index e69de29b..b9208f34 100644 --- a/test/fixtures/perldoc/BashCompletionModule.pm +++ b/test/fixtures/perldoc/BashCompletionModule.pm @@ -0,0 +1,4 @@ +package BashCompletionModule; +use strict; +use warnings; +1; diff --git a/test/fixtures/pytest/test_async.py b/test/fixtures/pytest/test_async.py new file mode 100644 index 00000000..48f91e08 --- /dev/null +++ b/test/fixtures/pytest/test_async.py @@ -0,0 +1,17 @@ +"""Async function pytest completion fixture.""" + + +async def test_positive(): + pass + + +async def non_test_negative(): + pass + + +class Testing: + async def test_positive(self): + pass + + async def non_test_negative(self): + pass diff --git a/test/fixtures/ssh-copy-id/.ssh/id_rsa b/test/fixtures/ssh-copy-id/.ssh/id_rsa new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/test/fixtures/ssh-copy-id/.ssh/id_rsa |