@@ -42,17 +42,16 @@ describe('aiohttp onboarding docs', function () {
42
42
43
43
// Does not render continuous profiling config
44
44
expect (
45
- screen . queryByText (
46
- textWithMarkupMatcher ( / " c o n t i n u o u s _ p r o f i l i n g _ a u t o _ s t a r t " : T r u e , / )
47
- )
45
+ screen . queryByText ( textWithMarkupMatcher ( / p r o f i l e _ s e s s i o n _ s a m p l e _ r a t e = 1 \. 0 , / ) )
46
+ ) . not . toBeInTheDocument ( ) ;
47
+ expect (
48
+ screen . queryByText ( textWithMarkupMatcher ( / p r o f i l e _ l i f e c y c l e = " t r a c e " , / ) )
48
49
) . not . toBeInTheDocument ( ) ;
49
50
50
51
// Does render transaction profiling config
51
- const matches = screen . getAllByText (
52
- textWithMarkupMatcher ( / p r o f i l e s _ s a m p l e _ r a t e = 1 \. 0 , / )
53
- ) ;
54
- expect ( matches . length ) . toBeGreaterThan ( 0 ) ;
55
- matches . forEach ( match => expect ( match ) . toBeInTheDocument ( ) ) ;
52
+ expect (
53
+ screen . getByText ( textWithMarkupMatcher ( / p r o f i l e s _ s a m p l e _ r a t e = 1 \. 0 , / ) )
54
+ ) . toBeInTheDocument ( ) ;
56
55
} ) ;
57
56
58
57
it ( 'renders continuous profiling' , function ( ) {
@@ -70,14 +69,15 @@ describe('aiohttp onboarding docs', function () {
70
69
71
70
// Does not render transaction profiling config
72
71
expect (
73
- screen . queryByText ( textWithMarkupMatcher ( / p r o f i l e s _ s a m p l e _ r a t e : 1 \. 0 , / ) )
72
+ screen . queryByText ( textWithMarkupMatcher ( / p r o f i l e s _ s a m p l e _ r a t e = 1 \. 0 , / ) )
74
73
) . not . toBeInTheDocument ( ) ;
75
74
76
75
// Does render continuous profiling config
77
- const matches = screen . getAllByText (
78
- textWithMarkupMatcher ( / " c o n t i n u o u s _ p r o f i l i n g _ a u t o _ s t a r t " : T r u e , / )
79
- ) ;
80
- expect ( matches . length ) . toBeGreaterThan ( 0 ) ;
81
- matches . forEach ( match => expect ( match ) . toBeInTheDocument ( ) ) ;
76
+ expect (
77
+ screen . getByText ( textWithMarkupMatcher ( / p r o f i l e _ s e s s i o n _ s a m p l e _ r a t e = 1 \. 0 , / ) )
78
+ ) . toBeInTheDocument ( ) ;
79
+ expect (
80
+ screen . getByText ( textWithMarkupMatcher ( / p r o f i l e _ l i f e c y c l e = " t r a c e " , / ) )
81
+ ) . toBeInTheDocument ( ) ;
82
82
} ) ;
83
83
} ) ;
0 commit comments