@@ -4,17 +4,6 @@ use backtrace::Backtrace;
4
4
5
5
const FRAME_RANGE : usize = 128 ; // should be close enough not to give false positives
6
6
7
- // FIXME: on Windows 32-bit ('i686-pc-windows-msvc') backtraces contain some spurious calls
8
- // which are not in the code (for instance calls to RtlFindCharInUnicodeString), however generated
9
- // backtraces are consistent between runs (so probably this is not an issue with synchronization?).
10
- // Until resolved those test are ignored and `Backtrace::ext_index()` always returns None.
11
- #[ test]
12
- #[ cfg_attr( not( all( target_os = "windows" , target_arch = "x86" ) ) , ignore) ]
13
- fn ext_index_must_be_0_on_win32 ( ) {
14
- let b = Backtrace :: new ( ) ;
15
- assert_eq ! ( b. ext_index( ) , 0 ) ;
16
- }
17
-
18
7
#[ test]
19
8
#[ cfg_attr( any( not( any( feature = "libunwind" , feature = "unix-backtrace" , feature = "dbghelp" ) ) , all( target_os = "windows" , target_arch = "x86" ) ) , ignore) ]
20
9
fn backtrace_new_unresolved_should_start_with_call_site_trace ( ) {
@@ -24,10 +13,9 @@ fn backtrace_new_unresolved_should_start_with_call_site_trace() {
24
13
println ! ( "{:#?}" , b) ;
25
14
26
15
assert ! ( !b. frames( ) . is_empty( ) ) ;
27
- assert ! ( b. ext_index( ) > 0 ) ;
28
16
29
17
let this_ip = backtrace_new_unresolved_should_start_with_call_site_trace as usize ;
30
- let frame_ip = b. ext_frames ( ) . first ( ) . unwrap ( ) . ip ( ) as usize ;
18
+ let frame_ip = b. frames ( ) . first ( ) . unwrap ( ) . ip ( ) as usize ;
31
19
32
20
assert ! ( frame_ip >= this_ip) ;
33
21
assert ! ( frame_ip <= this_ip + FRAME_RANGE ) ;
@@ -40,11 +28,10 @@ fn backtrace_new_should_start_with_call_site_trace() {
40
28
println ! ( "{:?}" , b) ;
41
29
42
30
assert ! ( !b. frames( ) . is_empty( ) ) ;
43
- assert ! ( b. ext_index( ) > 0 ) ;
44
31
45
32
let this_ip = backtrace_new_should_start_with_call_site_trace as usize ;
46
- let frame_ip = b. ext_frames ( ) . first ( ) . unwrap ( ) . ip ( ) as usize ;
33
+ let frame_ip = b. frames ( ) . first ( ) . unwrap ( ) . ip ( ) as usize ;
47
34
48
35
assert ! ( frame_ip >= this_ip) ;
49
36
assert ! ( frame_ip <= this_ip + FRAME_RANGE ) ;
50
- }
37
+ }
0 commit comments