@@ -167,17 +167,17 @@ mod ptrace {
167167 Ok ( WaitStatus :: Stopped ( child, SIGTRAP ) )
168168 ) ;
169169 // We want to test a syscall stop and a PTRACE_EVENT stop
170- assert ! ( ptrace:: setoptions(
170+ ptrace:: setoptions (
171171 child,
172- Options :: PTRACE_O_TRACESYSGOOD | Options :: PTRACE_O_TRACEEXIT
172+ Options :: PTRACE_O_TRACESYSGOOD | Options :: PTRACE_O_TRACEEXIT ,
173173 )
174- . is_ok ( ) ) ;
174+ . expect ( "setoptions failed" ) ;
175175
176176 // First, stop on the next system call, which will be exit()
177- assert ! ( ptrace:: syscall( child, None ) . is_ok ( ) ) ;
177+ ptrace:: syscall ( child, None ) . expect ( "syscall failed" ) ;
178178 assert_eq ! ( waitpid( child, None ) , Ok ( WaitStatus :: PtraceSyscall ( child) ) ) ;
179179 // Then get the ptrace event for the process exiting
180- assert ! ( ptrace:: cont( child, None ) . is_ok ( ) ) ;
180+ ptrace:: cont ( child, None ) . expect ( "cont failed" ) ;
181181 assert_eq ! (
182182 waitpid( child, None ) ,
183183 Ok ( WaitStatus :: PtraceEvent (
@@ -187,7 +187,7 @@ mod ptrace {
187187 ) )
188188 ) ;
189189 // Finally get the normal wait() result, now that the process has exited
190- assert ! ( ptrace:: cont( child, None ) . is_ok ( ) ) ;
190+ ptrace:: cont ( child, None ) . expect ( "cont failed" ) ;
191191 assert_eq ! ( waitpid( child, None ) , Ok ( WaitStatus :: Exited ( child, 0 ) ) ) ;
192192 }
193193
@@ -202,20 +202,20 @@ mod ptrace {
202202 Ok ( WaitStatus :: PtraceEvent ( child, SIGTRAP , 0 ) ) ,
203203 ) ;
204204 // We want to test a syscall stop and a PTRACE_EVENT stop
205- assert ! ( ptrace:: setoptions(
205+ ptrace:: setoptions (
206206 child,
207- Options :: PTRACE_O_TRACESYSGOOD | Options :: PTRACE_O_TRACEEXIT
207+ Options :: PTRACE_O_TRACESYSGOOD | Options :: PTRACE_O_TRACEEXIT ,
208208 )
209- . is_ok ( ) ) ;
209+ . expect ( "setopts failed" ) ;
210210
211211 // First, stop on the next system call, which will be exit()
212- assert ! ( ptrace:: syscall( child, None ) . is_ok ( ) ) ;
212+ ptrace:: syscall ( child, None ) . expect ( "syscall failed" ) ;
213213 assert_eq ! (
214214 waitid( Id :: Pid ( child) , WaitPidFlag :: WEXITED ) ,
215215 Ok ( WaitStatus :: PtraceSyscall ( child) ) ,
216216 ) ;
217217 // Then get the ptrace event for the process exiting
218- assert ! ( ptrace:: cont( child, None ) . is_ok ( ) ) ;
218+ ptrace:: cont ( child, None ) . expect ( "cont failed" ) ;
219219 assert_eq ! (
220220 waitid( Id :: Pid ( child) , WaitPidFlag :: WEXITED ) ,
221221 Ok ( WaitStatus :: PtraceEvent (
@@ -225,7 +225,7 @@ mod ptrace {
225225 ) ) ,
226226 ) ;
227227 // Finally get the normal wait() result, now that the process has exited
228- assert ! ( ptrace:: cont( child, None ) . is_ok ( ) ) ;
228+ ptrace:: cont ( child, None ) . expect ( "cont failed" ) ;
229229 assert_eq ! (
230230 waitid( Id :: Pid ( child) , WaitPidFlag :: WEXITED ) ,
231231 Ok ( WaitStatus :: Exited ( child, 0 ) ) ,
0 commit comments