Skip to content

Commit

Permalink
Remove duplicated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sgreenbury committed Jul 11, 2024
1 parent c6bb5aa commit 56753ea
Showing 1 changed file with 1 addition and 28 deletions.
29 changes: 1 addition & 28 deletions src/data_request_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -97,31 +97,4 @@ impl RegionSpec {
pub struct Polygon;

#[cfg(test)]
mod tests {

use std::str::FromStr;

use super::*;

#[test]
fn bbox_should_parse_if_correct() {
let bbox = BBox::from_str("0.0,1.0,2.0,3.0");
assert!(bbox.is_ok(), "A four coord bbox should parse");
}

#[test]
fn bbox_should_not_parse_if_incorrect() {
let bbox = BBox::from_str("0.0,1.0,2.0");
assert!(
bbox.is_err(),
"A string with fewer than 4 coords should not parse"
);
let bbox = BBox::from_str("0.0,1.0,2.0,3.0,4.0");
assert!(
bbox.is_err(),
"A string with 5 or more coords should not parse"
);
let bbox = BBox::from_str("0.0sdfsd,1.0,2.0");
assert!(bbox.is_err(), "A string with letters shouldn't parse");
}
}
mod tests {}

0 comments on commit 56753ea

Please sign in to comment.