Debian Codegraph @

third_party/rust/regex-syntax/test

raw
1 #!/bin/bash
2
3 set -e
4
5 # cd to the directory containing this crate's Cargo.toml so that we don't need
6 # to pass --manifest-path to every `cargo` command.
7 cd "$(dirname "$0")"
8
9 # This is a convenience script for running a broad swath of the syntax tests.
10 echo "===== DEFAULT FEATURES ==="
11 cargo test
12
13 features=(
14 std
15 unicode
16 unicode-age
17 unicode-bool
18 unicode-case
19 unicode-gencat
20 unicode-perl
21 unicode-script
22 unicode-segment
23 )
24 for f in "${features[@]}"; do
25 echo "=== FEATURE: $f ==="
26 # We only run library tests because I couldn't figure out how to easily
27 # make doc tests run in 'no_std' mode. In particular, without the Error
28 # trait, using '?' in doc tests seems tricky.
29 cargo test --no-default-features --lib --features "$f"
30 done