File tree 3 files changed +14
-5
lines changed
3 files changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -516,6 +516,7 @@ pub mod tests {
516
516
assert!( crate :: handle:: refcount( fileid) . is_err( ) ) ;
517
517
assert!( crate :: handle:: refcount( groupid) . is_err( ) ) ;
518
518
assert!( !group. is_valid( ) ) ;
519
+ drop( group) ;
519
520
} ) ;
520
521
} ) ;
521
522
}
Original file line number Diff line number Diff line change @@ -269,6 +269,9 @@ pub mod tests {
269
269
h5lock ! ( {
270
270
file. close( ) . unwrap( ) ;
271
271
assert_eq!( format!( "{:?}" , a) , "<HDF5 group: invalid id>" ) ;
272
+ drop( a) ;
273
+ drop( ab) ;
274
+ drop( abc) ;
272
275
} )
273
276
} )
274
277
}
Original file line number Diff line number Diff line change @@ -124,11 +124,14 @@ pub mod tests {
124
124
obj. decref ( ) ;
125
125
assert_eq ! ( obj. refcount( ) , 1 ) ;
126
126
obj. decref ( ) ;
127
- obj. decref ( ) ;
128
- assert_eq ! ( obj. refcount( ) , 0 ) ;
129
- assert ! ( !obj. is_valid( ) ) ;
130
- assert ! ( !is_valid_user_id( obj. id( ) ) ) ;
131
- assert ! ( !is_valid_id( obj. id( ) ) ) ;
127
+ h5lock ! ( {
128
+ obj. decref( ) ;
129
+ assert_eq!( obj. refcount( ) , 0 ) ;
130
+ assert!( !obj. is_valid( ) ) ;
131
+ assert!( !is_valid_user_id( obj. id( ) ) ) ;
132
+ assert!( !is_valid_id( obj. id( ) ) ) ;
133
+ drop( obj) ;
134
+ } ) ;
132
135
}
133
136
134
137
#[ test]
@@ -166,6 +169,8 @@ pub mod tests {
166
169
obj. decref( ) ;
167
170
assert!( !obj. is_valid( ) ) ;
168
171
assert!( !obj2. is_valid( ) ) ;
172
+ drop( obj) ;
173
+ drop( obj2) ;
169
174
} ) ;
170
175
}
171
176
}
You can’t perform that action at this time.
0 commit comments