dont warn dead code for test utils
This commit is contained in:
parent
f78257a1fc
commit
7ebcbab9ac
|
@ -79,6 +79,7 @@ pub fn torrent_to_magnet<T: AsRef<Path>>(torrent: T) -> Result<String, Error> {
|
|||
}
|
||||
|
||||
// Fallible: only used in tests
|
||||
#[allow(dead_code)]
|
||||
pub fn find_free_port() -> u16 {
|
||||
let bind = TcpListener::bind("127.0.0.1:0").unwrap();
|
||||
bind.local_addr().unwrap().port()
|
||||
|
|
Loading…
Reference in New Issue
Block a user