Skip to content

Commit df101fb

Browse files
committedDec 18, 2024
Merge #1141: Don't execute slow doc tests
0e13ff7 fix: [1097] do not compile slow doc tests (Jose Celano) Pull request description: This PR disables slow doc tests. They are slow because they include the main library, and each test has to compile it. They will be enabled again after [moving the code to workspace sub-packages](#1140) that do not depend on the main tracker lib. ACKs for top commit: josecelano: ACK 0e13ff7 Tree-SHA512: fc5542deaabea3c66c4b6994736e89470052dac90db7bd4739c3033aa6de81a6de62c3e37d793f05524dbb92328c3683b7f4fd615303a0839e00829bf500dec4
2 parents f113d2c + 0e13ff7 commit df101fb

File tree

8 files changed

+14
-14
lines changed

8 files changed

+14
-14
lines changed
 

‎src/core/auth.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ impl Key {
196196

197197
/// Error returned when a key cannot be parsed from a string.
198198
///
199-
/// ```rust,no_run
199+
/// ```text
200200
/// use torrust_tracker::core::auth::Key;
201201
/// use std::str::FromStr;
202202
///

‎src/core/databases/driver.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ pub enum Driver {
2929
///
3030
/// Example for `SQLite3`:
3131
///
32-
/// ```rust,no_run
32+
/// ```text
3333
/// use torrust_tracker::core::databases;
3434
/// use torrust_tracker::core::databases::driver::Driver;
3535
///
@@ -40,7 +40,7 @@ pub enum Driver {
4040
///
4141
/// Example for `MySQL`:
4242
///
43-
/// ```rust,no_run
43+
/// ```text
4444
/// use torrust_tracker::core::databases;
4545
/// use torrust_tracker::core::databases::driver::Driver;
4646
///

‎src/servers/http/v1/query.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ impl Query {
3030
/// It return `Some(value)` for a URL query param if the param with the
3131
/// input `name` exists. For example:
3232
///
33-
/// ```rust
33+
/// ```text
3434
/// use torrust_tracker::servers::http::v1::query::Query;
3535
///
3636
/// let raw_query = "param1=value1&param2=value2";
@@ -43,7 +43,7 @@ impl Query {
4343
///
4444
/// It returns only the first param value even if it has multiple values:
4545
///
46-
/// ```rust
46+
/// ```text
4747
/// use torrust_tracker::servers::http::v1::query::Query;
4848
///
4949
/// let raw_query = "param1=value1&param1=value2";
@@ -59,7 +59,7 @@ impl Query {
5959

6060
/// Returns all the param values as a vector.
6161
///
62-
/// ```rust
62+
/// ```text
6363
/// use torrust_tracker::servers::http::v1::query::Query;
6464
///
6565
/// let query = "param1=value1&param1=value2".parse::<Query>().unwrap();
@@ -72,7 +72,7 @@ impl Query {
7272
///
7373
/// Returns all the param values as a vector even if it has only one value.
7474
///
75-
/// ```rust
75+
/// ```text
7676
/// use torrust_tracker::servers::http::v1::query::Query;
7777
///
7878
/// let query = "param1=value1".parse::<Query>().unwrap();

‎src/servers/http/v1/requests/announce.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ const NUMWANT: &str = "numwant";
2929
/// The `Announce` request. Fields use the domain types after parsing the
3030
/// query params of the request.
3131
///
32-
/// ```rust
32+
/// ```text
3333
/// use aquatic_udp_protocol::{NumberOfBytes, PeerId};
3434
/// use torrust_tracker::servers::http::v1::requests::announce::{Announce, Compact, Event};
3535
/// use bittorrent_primitives::info_hash::InfoHash;

‎src/servers/http/v1/responses/announce.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ impl Into<Vec<u8>> for Compact {
152152

153153
/// A [`NormalPeer`], for the [`Normal`] form.
154154
///
155-
/// ```rust
155+
/// ```text
156156
/// use std::net::{IpAddr, Ipv4Addr};
157157
/// use torrust_tracker::servers::http::v1::responses::announce::{Normal, NormalPeer};
158158
///
@@ -204,7 +204,7 @@ impl From<&NormalPeer> for BencodeMut<'_> {
204204
/// A part from reducing the size of the response, this format does not contain
205205
/// the peer's ID.
206206
///
207-
/// ```rust
207+
/// ```text
208208
/// use std::net::{IpAddr, Ipv4Addr};
209209
/// use torrust_tracker::servers::http::v1::responses::announce::{Compact, CompactPeer, CompactPeerData};
210210
///

‎src/servers/http/v1/responses/error.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ pub struct Error {
2626
impl Error {
2727
/// Returns the bencoded representation of the `Error` struct.
2828
///
29-
/// ```rust
29+
/// ```text
3030
/// use torrust_tracker::servers::http::v1::responses::error::Error;
3131
///
3232
/// let err = Error {

‎src/servers/http/v1/responses/scrape.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use crate::core::ScrapeData;
1111

1212
/// The `Scrape` response for the HTTP tracker.
1313
///
14-
/// ```rust
14+
/// ```text
1515
/// use torrust_tracker::servers::http::v1::responses::scrape::Bencoded;
1616
/// use bittorrent_primitives::info_hash::InfoHash;
1717
/// use torrust_tracker_primitives::swarm_metadata::SwarmMetadata;

‎src/servers/http/v1/services/peer_ip_resolver.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ pub enum PeerIpResolutionError {
5959
///
6060
/// With the tracker running on reverse proxy mode:
6161
///
62-
/// ```rust
62+
/// ```text
6363
/// use std::net::IpAddr;
6464
/// use std::str::FromStr;
6565
///
@@ -81,7 +81,7 @@ pub enum PeerIpResolutionError {
8181
///
8282
/// With the tracker non running on reverse proxy mode:
8383
///
84-
/// ```rust
84+
/// ```text
8585
/// use std::net::IpAddr;
8686
/// use std::str::FromStr;
8787
///

0 commit comments

Comments
 (0)