@@ -51,3 +51,68 @@ def test_hides_dcl_items_in_member(self):
5151 self .assert_text_in_body ("void always_visible" )
5252 self .assert_text_in_body ("void not_visible_in_cxx98" )
5353 self .assert_text_not_in_body ("void not_visible_in_cxx11" )
54+
55+ def test_rewrites_numbers_in_dcl (self ):
56+ self .get_page ("test-gadget-stdrev/rewrites-numbers-in-dcl" )
57+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
58+ self .assert_text_once_in_body ('visible_always_2' )
59+ self .assert_text_once_in_body ('visible_until_cxx14_3' )
60+ self .assert_text_once_in_body ('(1)' )
61+ self .assert_text_once_in_body ('(2)' )
62+ self .assert_text_once_in_body ('(3)' )
63+ self .assert_text_once_in_body ('1) option_1_visible_since_cxx11' )
64+ self .assert_text_once_in_body ('2) option_2_visible_always' )
65+ self .assert_text_once_in_body ('3) option_3_visible_until_cxx14' )
66+
67+ self .select_cxx98 ()
68+ self .assert_text_not_in_body ('visible_since_cxx11_1' )
69+ self .assert_text_once_in_body ('visible_always_2' )
70+ self .assert_text_once_in_body ('visible_until_cxx14_3' )
71+ self .assert_text_once_in_body ('(1)' )
72+ self .assert_text_once_in_body ('(2)' )
73+ self .assert_text_not_in_body ('(3)' )
74+ self .assert_text_not_in_body ('option_1_visible_since_cxx11' )
75+ self .assert_text_once_in_body ('1) option_2_visible_always' )
76+ self .assert_text_once_in_body ('2) option_3_visible_until_cxx14' )
77+
78+ self .select_cxx11 ()
79+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
80+ self .assert_text_once_in_body ('visible_always_2' )
81+ self .assert_text_once_in_body ('visible_until_cxx14_3' )
82+ self .assert_text_once_in_body ('(1)' )
83+ self .assert_text_once_in_body ('(2)' )
84+ self .assert_text_once_in_body ('(3)' )
85+ self .assert_text_once_in_body ('1) option_1_visible_since_cxx11' )
86+ self .assert_text_once_in_body ('2) option_2_visible_always' )
87+ self .assert_text_once_in_body ('3) option_3_visible_until_cxx14' )
88+
89+ self .select_cxx14 ()
90+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
91+ self .assert_text_once_in_body ('visible_always_2' )
92+ self .assert_text_not_in_body ('visible_until_cxx14_3' )
93+ self .assert_text_once_in_body ('(1)' )
94+ self .assert_text_once_in_body ('(2)' )
95+ self .assert_text_not_in_body ('(3)' )
96+ self .assert_text_once_in_body ('1) option_1_visible_since_cxx11' )
97+ self .assert_text_once_in_body ('2) option_2_visible_always' )
98+ self .assert_text_not_in_body ('3) option_3_visible_until_cxx14' )
99+
100+ def test_rewrites_numbers_in_dcl_range (self ):
101+ self .get_page ("test-gadget-stdrev/rewrites-numbers-in-dcl-range" )
102+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
103+ self .assert_text_once_in_body ('visible_on_cxx11_2' )
104+ self .assert_text_once_in_body ('visible_since_cxx14_2' )
105+ self .assert_text_once_in_body ('(1)' )
106+ self .assert_text_once_in_body ('(2)' )
107+
108+ self .select_cxx11 ()
109+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
110+ self .assert_text_once_in_body ('visible_on_cxx11_2' )
111+ self .assert_text_once_in_body ('(1)' )
112+ self .assert_text_once_in_body ('(2)' )
113+
114+ self .select_cxx14 ()
115+ self .assert_text_once_in_body ('visible_since_cxx11_1' )
116+ self .assert_text_once_in_body ('visible_since_cxx14_2' )
117+ self .assert_text_once_in_body ('(1)' )
118+ self .assert_text_once_in_body ('(2)' )
0 commit comments