Nothing, just fixed tests and updated buffers debugging

This commit is contained in:
Igor Katson 2021-07-09 23:18:59 +01:00
parent 7a947ddf79
commit 7d7d82ac6d
4 changed files with 36 additions and 23 deletions

View file

@ -256,11 +256,12 @@ mod tests {
use super::*;
const TORRENT_FILENAME: &str = "../librqbit/resources/ubuntu-21.04-desktop-amd64.iso.torrent";
#[test]
fn test_deserialize_torrent_owned() {
let mut buf = Vec::new();
let filename = "resources/ubuntu-21.04-desktop-amd64.iso.torrent";
std::fs::File::open(filename)
std::fs::File::open(TORRENT_FILENAME)
.unwrap()
.read_to_end(&mut buf)
.unwrap();
@ -272,8 +273,7 @@ mod tests {
#[test]
fn test_deserialize_torrent_borrowed() {
let mut buf = Vec::new();
let filename = "resources/ubuntu-21.04-desktop-amd64.iso.torrent";
std::fs::File::open(filename)
std::fs::File::open(TORRENT_FILENAME)
.unwrap()
.read_to_end(&mut buf)
.unwrap();
@ -285,8 +285,7 @@ mod tests {
#[test]
fn test_deserialize_torrent_with_info_hash() {
let mut buf = Vec::new();
let filename = "resources/ubuntu-21.04-desktop-amd64.iso.torrent";
std::fs::File::open(filename)
std::fs::File::open(TORRENT_FILENAME)
.unwrap()
.read_to_end(&mut buf)
.unwrap();