Skip to content

Commit 883aad8

Browse files
shrink tests
1 parent 6003d0f commit 883aad8

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

simd-minimizers/src/test.rs

+3-7
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ fn swap_gt(c: u8) -> u8 {
1515
}
1616
}
1717

18-
static ASCII_SEQ: LazyLock<AsciiSeqVec> = LazyLock::new(|| AsciiSeqVec::random(1024 * 32));
18+
static ASCII_SEQ: LazyLock<AsciiSeqVec> = LazyLock::new(|| AsciiSeqVec::random(1024));
1919
static SLICE: LazyLock<Vec<u8>> =
2020
LazyLock::new(|| ASCII_SEQ.seq.iter().copied().map(swap_gt).collect_vec());
2121
static PACKED_SEQ: LazyLock<PackedSeqVec> =
@@ -31,11 +31,7 @@ fn test_on_inputs(f: impl Fn(usize, usize, &[u8], AsciiSeq, PackedSeq)) {
3131
let mut lens = (0..100).collect_vec();
3232
ks.extend((0..10).map(|_| rng.random_range(6..100)).collect_vec());
3333
ws.extend((0..10).map(|_| rng.random_range(6..100)).collect_vec());
34-
lens.extend(
35-
(0..10)
36-
.map(|_| rng.random_range(100..1024 * 32))
37-
.collect_vec(),
38-
);
34+
lens.extend((0..10).map(|_| rng.random_range(100..1024)).collect_vec());
3935
for &k in &ks {
4036
for &w in &ws {
4137
for &len in &lens {
@@ -107,7 +103,7 @@ fn nthash_canonical_is_revcomp() {
107103
for k in [
108104
1, 2, 3, 4, 5, 6, 7, 8, 9, 15, 16, 17, 31, 32, 33, 63, 64, 65,
109105
] {
110-
for len in (0..100).chain(once(1024 * 32)) {
106+
for len in (0..100).chain(once(1024)) {
111107
let seq = seq.slice(0..len);
112108
let seq_rc = seq_rc.slice(seq_rc.len() - len..seq_rc.len());
113109
let scalar = nthash_seq_scalar::<true, H>(seq, k).collect::<Vec<_>>();

0 commit comments

Comments
 (0)