diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2023-04-13 15:43:45 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2023-04-13 15:43:45 +0900 |
commit | 367508b61123110135ea7a3058dd85a82ba07c2f (patch) | |
tree | 27669792827cdc87391bfb66032615e2a2bf5d5b | |
parent | 445360d578409116aa39dad44710d2ed993f706d (diff) | |
download | rust-ahash-accepted/tizen_unified.tar.gz rust-ahash-accepted/tizen_unified.tar.bz2 rust-ahash-accepted/tizen_unified.zip |
Add unittesttizen_9.0_m2_releaseaccepted/tizen/unified/x/20240328.130525accepted/tizen/unified/dev/20240620.001027accepted/tizen/unified/20240328.121549accepted/tizen/rust/20231016.020734accepted/tizen/9.0/unified/20241030.234457tizen_9.0tizenaccepted/tizen_unified_xaccepted/tizen_unified_devaccepted/tizen_unifiedaccepted/tizen_rustaccepted/tizen_9.0_unified
[ 25s] running 31 tests
[ 25s] test fallback_hash::tests::test_conversion ... ok
[ 25s] test fallback_hash::tests::test_hash ... ok
[ 25s] test hash_map::test::test_borrow ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_finish_is_consistant ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_all_bytes_matter ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_input_affect_every_byte ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_keys_affect_every_byte ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_keys_change_output ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_length_extension ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_single_key_bit_flip ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_single_bit_flip ... ok
[ 25s] test operations::test::test_add_length ... ok
[ 25s] test operations::test::test_shuffle_contains_each_value ... ok
[ 25s] test operations::test::test_shuffle_moves_every_value ... ok
[ 25s] test operations::test::test_shuffle_moves_high_bits ... ok
[ 25s] test random_state::test::test_not_pi ... ok
[ 25s] test random_state::test::test_unique ... ok
[ 25s] test specialize::test::test_input_processed ... ok
[ 25s] test random_state::test::test_with_seeds_const ... ok
[ 25s] test specialize::test::test_ref_independent ... ok
[ 25s] test test::test_ahash_alias_map_construction ... ok
[ 25s] test test::test_ahash_alias_set_construction ... ok
[ 25s] test test::test_ahasher_construction ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_test_no_pair_collisions ... ok
[ 25s] test test::test_conversion ... ok
[ 25s] test test::test_default_builder ... ok
[ 25s] test test::test_builder ... ok
[ 25s] test test::test_non_zero ... ok
[ 25s] test test::test_non_zero_specialized ... ok
[ 25s] test hash_quality_test::fallback_tests::fallback_padding_doesnot_collide ... ok
[ 58s] test hash_quality_test::fallback_tests::fallback_test_no_full_collisions ... ok
[ 58s]
[ 58s] test result: ok. 31 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 33.40s
-rw-r--r-- | packaging/rust-ahash.spec | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/packaging/rust-ahash.spec b/packaging/rust-ahash.spec index b68bbf8..a22a9b1 100644 --- a/packaging/rust-ahash.spec +++ b/packaging/rust-ahash.spec @@ -33,6 +33,10 @@ BuildRequires: rust-version_check Requires: rust-getrandom Requires: rust-once_cell +%if 0%{?run_tests} +BuildRequires: rust-hex +%endif + %description Non-cryptographic hash function using AES-NI for high performance. @@ -62,6 +66,21 @@ cp %{SOURCE1} . install -d -m 0755 %{buildroot}%{_rust_dylibdir} install -m 0644 lib%{real_crate_name}.so %{buildroot}/%{_rust_dylibdir}/lib%{real_crate_name}.so +%check +%if 0%{?run_tests} +%{rustc_std_build} --test --crate-type=dylib \ + --crate-name=%{real_crate_name} \ + %{?rustc_edition:--edition=%{rustc_edition}} \ + --cfg='feature="std"' \ + --cfg='feature="runtime-rng"' \ + --cfg='feature="atomic-polyfill"' \ + %rust_dylib_extern cfg_if \ + %rust_dylib_extern hex \ + ./src/lib.rs + +./%{real_crate_name} +%endif + %clean %post -p /sbin/ldconfig |