diff options
author | 김명운/Tizen Platform Lab(SR)/삼성전자 <myoungwoon.kim@samsung.com> | 2023-05-12 16:45:14 +0900 |
---|---|---|
committer | GitHub Enterprise <noreply-CODE@samsung.com> | 2023-05-12 16:45:14 +0900 |
commit | 2385b829b11321f4d45ef0c0d3de1eb9996b8cae (patch) | |
tree | bbe2ecc0fed66427060a1bcd811ff894d806a204 | |
parent | 2dbd0e3f5160ad00862c93895bbadc15e00b33dd (diff) | |
parent | 808f9d99baf5036992b8e9bfb8caa6b45e927694 (diff) | |
download | rust-serde-accepted/tizen_unified_x.tar.gz rust-serde-accepted/tizen_unified_x.tar.bz2 rust-serde-accepted/tizen_unified_x.zip |
Merge pull request #1 from myoungwoon-kim/devtizen_9.0_m2_releaseaccepted/tizen/unified/x/20240328.130855accepted/tizen/unified/dev/20240620.002411accepted/tizen/unified/20240328.123215accepted/tizen/rust/20231016.021851accepted/tizen/9.0/unified/20241030.232836tizen_9.0tizenaccepted/tizen_unified_xaccepted/tizen_unified_devaccepted/tizen_unifiedaccepted/tizen_rustaccepted/tizen_9.0_unified
Add unittest
-rw-r--r-- | packaging/rust-serde.spec | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/packaging/rust-serde.spec b/packaging/rust-serde.spec index b58ceae..4da199e 100644 --- a/packaging/rust-serde.spec +++ b/packaging/rust-serde.spec @@ -51,6 +51,19 @@ 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} \ + --cfg='feature="default"' \ + --cfg='feature="std"' \ + --cfg='feature="serde_derive"' \ + -lserde_derive \ + ./src/lib.rs + +./%{real_crate_name} +%endif + %clean %post -p /sbin/ldconfig |