Skip to content

Commit

Permalink
Move std::num unit tests to integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bjorn3 authored and gitbot committed Feb 20, 2025
1 parent 03131a8 commit 361d3bc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 0 additions & 3 deletions std/src/num.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@
#![stable(feature = "rust1", since = "1.0.0")]
#![allow(missing_docs)]

#[cfg(test)]
mod tests;

#[stable(feature = "int_error_matching", since = "1.55.0")]
pub use core::num::IntErrorKind;
#[stable(feature = "generic_nonzero", since = "1.79.0")]
Expand Down
6 changes: 3 additions & 3 deletions std/src/num/tests.rs → std/tests/num.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::ops::Mul;
use std::ops::Mul;

#[test]
fn test_saturating_add_uint() {
Expand Down Expand Up @@ -190,8 +190,8 @@ fn test_uint_to_str_overflow() {
assert_eq!(u64_val.to_string(), "0");
}

fn from_str<T: crate::str::FromStr>(t: &str) -> Option<T> {
crate::str::FromStr::from_str(t).ok()
fn from_str<T: std::str::FromStr>(t: &str) -> Option<T> {
std::str::FromStr::from_str(t).ok()
}

#[test]
Expand Down

0 comments on commit 361d3bc

Please sign in to comment.