Skip to content

Commit 0edce0d

Browse files
committed
comment out compile-fail test
the `cfg(compile_fail)` attribute relied upon 'features', requiring the following test command: `cargo test --features compile_fail`. this was not being covered in automated testing. since rust 1.80 when running `cargo test` i get a warning output about `compile_fail` being an unknown config attribute (not included in the list of features in the cargo.toml file). if i try to execute it with the feature flag enabled i get an error preventing me from using it. there is no `#[compile_fail]` attribute yet, rust only supports this in doc comment tests. so solutions are either to: - move this to a doc test, but i don't want this to appear in documentation. - add `compile_fail` to the list of features - comment out the code and only uncomment it if/when wanting to check that the test still works. if i decide to always include it in automated testing then i'll have to add it to the features list. otherwise i'll just comment it out for now.
1 parent f5e86e5 commit 0edce0d

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

pulse-binding/src/proplist.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -514,11 +514,10 @@ impl Clone for Proplist {
514514
#[cfg(test)]
515515
mod tests {
516516
use super::*;
517-
517+
/*
518518
/// Test that you cannot create a use-after-free situation by destroying a `Proplist` before an
519519
/// associated `Iterator` (we avoid `Rc`/`Arc`).
520520
#[test]
521-
#[cfg(compile_fail)]
522521
fn proplist_iter_lifetime() {
523522
let iter = {
524523
let my_props = Proplist::new().unwrap();
@@ -530,7 +529,7 @@ mod tests {
530529
println!("key: {}", key);
531530
}
532531
}
533-
532+
*/
534533
/// Test that you can however return an iterator if you convert the `Proplist` into one
535534
#[test]
536535
fn proplist_iter_lifetime_conv() {

0 commit comments

Comments
 (0)