mirror of
https://github.com/Serial-ATA/lofty-rs
synced 2024-12-13 14:12:31 +00:00
Tests: Convert EBML tests to test_log
This commit is contained in:
parent
761b37f655
commit
9cfa003f48
2 changed files with 10 additions and 10 deletions
|
@ -327,7 +327,7 @@ mod tests {
|
|||
],
|
||||
];
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn bytes_to_vint() {
|
||||
for representation in VALID_REPRESENTATIONS_OF_2 {
|
||||
assert_eq!(
|
||||
|
@ -339,7 +339,7 @@ mod tests {
|
|||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn vint_to_bytes() {
|
||||
for representation in VALID_REPRESENTATIONS_OF_2 {
|
||||
let vint = VInt::parse(&mut Cursor::new(representation), 8).unwrap();
|
||||
|
@ -350,7 +350,7 @@ mod tests {
|
|||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn large_integers_should_fail() {
|
||||
assert!(VInt::from_u64(u64::MAX).is_err());
|
||||
|
||||
|
@ -361,12 +361,12 @@ mod tests {
|
|||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn maximum_possible_representable_vint() {
|
||||
assert!(VInt::from_u64(u64::MAX >> 8).is_ok());
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn octet_lengths() {
|
||||
let n = u64::MAX >> 8;
|
||||
for i in 1u8..=7 {
|
||||
|
|
|
@ -7,7 +7,7 @@ use lofty::tag::TagType;
|
|||
|
||||
use std::io::Seek;
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn read() {
|
||||
// This file contains a tags element
|
||||
let file = Probe::open("tests/files/assets/minimal/full_test.mka")
|
||||
|
@ -22,7 +22,7 @@ fn read() {
|
|||
crate::verify_artist!(file, primary_tag, "Foo artist", 1);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn write() {
|
||||
let mut file = temp_file!("tests/files/assets/minimal/full_test.mka");
|
||||
|
||||
|
@ -51,17 +51,17 @@ fn write() {
|
|||
crate::set_artist!(tagged_file, tag_mut, TagType::Ebml, "Bar artist", 1 => file, "Foo artist");
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn remove() {
|
||||
crate::remove_tag!("tests/files/assets/minimal/full_test.mka", TagType::Ebml);
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn read_no_properties() {
|
||||
crate::no_properties_test!("tests/files/assets/minimal/full_test.mka");
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[test_log::test]
|
||||
fn read_no_tags() {
|
||||
crate::no_tag_test!("tests/files/assets/minimal/full_test.mka");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue