File: test

package info (click to toggle)
rust-regex-syntax 0.8.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,812 kB
  • sloc: sh: 19; makefile: 4
file content (30 lines) | stat: -rwxr-xr-x 783 bytes parent folder | download | duplicates (47)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/bin/bash

set -e

# cd to the directory containing this crate's Cargo.toml so that we don't need
# to pass --manifest-path to every `cargo` command.
cd "$(dirname "$0")"

# This is a convenience script for running a broad swath of the syntax tests.
echo "===== DEFAULT FEATURES ==="
cargo test

features=(
    std
    unicode
    unicode-age
    unicode-bool
    unicode-case
    unicode-gencat
    unicode-perl
    unicode-script
    unicode-segment
)
for f in "${features[@]}"; do
    echo "=== FEATURE: $f ==="
    # We only run library tests because I couldn't figure out how to easily
    # make doc tests run in 'no_std' mode. In particular, without the Error
    # trait, using '?' in doc tests seems tricky.
    cargo test --no-default-features --lib --features "$f"
done