editorconfig / editorconfig-core-py

Clone of EditorConfig core written in Python
http://editorconfig.org
Other
93 stars 23 forks source link

fix: only support Python3 #48

Closed greut closed 10 months ago

greut commented 10 months ago

Closes #47

$ cmake -DPYTHON_EXECUTABLE=/usr/bin/python3.12
-- Tests are in /home/yoan/soft/editorconfig-core-py/tests
-- tests: Using editorconfig binary /usr/bin/python3.12;-m;editorconfig
-- meta: Using editorconfig /usr/bin/python3.12;-m;editorconfig
-- Configuring done (0.0s)
-- Generating done (0.0s)
-- Build files have been written to: /home/yoan/soft/editorconfig-core-py

$ ctest .
Test project /home/yoan/soft/editorconfig-core-py
        Start   1: meta_runandsort
  1/197 Test   #1: meta_runandsort ...........................   Passed    0.01 sec
        Start   2: meta_multiline
  2/197 Test   #2: meta_multiline ............................   Passed    0.04 sec
        Start   3: star_single_ML
  3/197 Test   #3: star_single_ML ............................   Passed    0.04 sec
        Start   4: star_zero_ML
  4/197 Test   #4: star_zero_ML ..............................   Passed    0.03 sec
        Start   5: star_multiple_ML
  5/197 Test   #5: star_multiple_ML ..........................   Passed    0.03 sec
        Start   6: star_over_slash
  6/197 Test   #6: star_over_slash ...........................   Passed    0.03 sec
        Start   7: star_after_slash_ML
  7/197 Test   #7: star_after_slash_ML .......................   Passed    0.03 sec
        Start   8: star_matches_dot_file_after_slash_ML
  8/197 Test   #8: star_matches_dot_file_after_slash_ML ......   Passed    0.03 sec
        Start   9: star_matches_dot_file
  9/197 Test   #9: star_matches_dot_file .....................   Passed    0.03 sec
        Start  10: question_single
 10/197 Test  #10: question_single ...........................   Passed    0.03 sec
        Start  11: question_zero
 11/197 Test  #11: question_zero .............................   Passed    0.03 sec
        Start  12: question_multiple
 12/197 Test  #12: question_multiple .........................   Passed    0.03 sec
        Start  13: question_slash
 13/197 Test  #13: question_slash ............................   Passed    0.03 sec
        Start  14: brackets_close_inside
 14/197 Test  #14: brackets_close_inside .....................   Passed    0.03 sec
        Start  15: brackets_close_outside
 15/197 Test  #15: brackets_close_outside ....................   Passed    0.03 sec
        Start  16: brackets_nclose_inside
 16/197 Test  #16: brackets_nclose_inside ....................   Passed    0.03 sec
        Start  17: brackets_nclose_outside
 17/197 Test  #17: brackets_nclose_outside ...................   Passed    0.03 sec
        Start  18: brackets_choice
 18/197 Test  #18: brackets_choice ...........................   Passed    0.03 sec
        Start  19: brackets_choice2
 19/197 Test  #19: brackets_choice2 ..........................   Passed    0.03 sec
        Start  20: brackets_nchoice
 20/197 Test  #20: brackets_nchoice ..........................   Passed    0.03 sec
        Start  21: brackets_nchoice2
 21/197 Test  #21: brackets_nchoice2 .........................   Passed    0.03 sec
        Start  22: brackets_range
 22/197 Test  #22: brackets_range ............................   Passed    0.03 sec
        Start  23: brackets_range2
 23/197 Test  #23: brackets_range2 ...........................   Passed    0.03 sec
        Start  24: brackets_nrange
 24/197 Test  #24: brackets_nrange ...........................   Passed    0.03 sec
        Start  25: brackets_nrange2
 25/197 Test  #25: brackets_nrange2 ..........................   Passed    0.03 sec
        Start  26: brackets_range_and_choice
 26/197 Test  #26: brackets_range_and_choice .................   Passed    0.03 sec
        Start  27: brackets_choice_with_dash
 27/197 Test  #27: brackets_choice_with_dash .................   Passed    0.03 sec
        Start  28: brackets_slash_inside1
 28/197 Test  #28: brackets_slash_inside1 ....................   Passed    0.03 sec
        Start  29: brackets_slash_inside2
 29/197 Test  #29: brackets_slash_inside2 ....................   Passed    0.03 sec
        Start  30: brackets_slash_inside3
 30/197 Test  #30: brackets_slash_inside3 ....................   Passed    0.03 sec
        Start  31: brackets_slash_inside4
 31/197 Test  #31: brackets_slash_inside4 ....................   Passed    0.03 sec
        Start  32: braces_word_choice1
 32/197 Test  #32: braces_word_choice1 .......................   Passed    0.03 sec
        Start  33: braces_word_choice2
 33/197 Test  #33: braces_word_choice2 .......................   Passed    0.03 sec
        Start  34: braces_word_choice3
 34/197 Test  #34: braces_word_choice3 .......................   Passed    0.03 sec
        Start  35: braces_word_choice4
 35/197 Test  #35: braces_word_choice4 .......................   Passed    0.03 sec
        Start  36: braces_single_choice
 36/197 Test  #36: braces_single_choice ......................   Passed    0.03 sec
        Start  37: braces_single_choice_negative
 37/197 Test  #37: braces_single_choice_negative .............   Passed    0.03 sec
        Start  38: braces_empty_choice
 38/197 Test  #38: braces_empty_choice .......................   Passed    0.03 sec
        Start  39: braces_empty_choice_negative
 39/197 Test  #39: braces_empty_choice_negative ..............   Passed    0.03 sec
        Start  40: braces_empty_word1
 40/197 Test  #40: braces_empty_word1 ........................   Passed    0.03 sec
        Start  41: braces_empty_word2
 41/197 Test  #41: braces_empty_word2 ........................   Passed    0.03 sec
        Start  42: braces_empty_word3
 42/197 Test  #42: braces_empty_word3 ........................   Passed    0.03 sec
        Start  43: braces_empty_word4
 43/197 Test  #43: braces_empty_word4 ........................   Passed    0.03 sec
        Start  44: braces_empty_words1
 44/197 Test  #44: braces_empty_words1 .......................   Passed    0.03 sec
        Start  45: braces_empty_words2
 45/197 Test  #45: braces_empty_words2 .......................   Passed    0.03 sec
        Start  46: braces_empty_words3
 46/197 Test  #46: braces_empty_words3 .......................   Passed    0.03 sec
        Start  47: braces_empty_words4
 47/197 Test  #47: braces_empty_words4 .......................   Passed    0.03 sec
        Start  48: braces_no_closing
 48/197 Test  #48: braces_no_closing .........................   Passed    0.03 sec
        Start  49: braces_no_closing_negative
 49/197 Test  #49: braces_no_closing_negative ................   Passed    0.03 sec
        Start  50: braces_nested1
 50/197 Test  #50: braces_nested1 ............................   Passed    0.03 sec
        Start  51: braces_nested2
 51/197 Test  #51: braces_nested2 ............................   Passed    0.03 sec
        Start  52: braces_nested3
 52/197 Test  #52: braces_nested3 ............................   Passed    0.03 sec
        Start  53: braces_nested4
 53/197 Test  #53: braces_nested4 ............................   Passed    0.03 sec
        Start  54: braces_nested5
 54/197 Test  #54: braces_nested5 ............................   Passed    0.03 sec
        Start  55: braces_nested_start1
 55/197 Test  #55: braces_nested_start1 ......................   Passed    0.03 sec
        Start  56: braces_nested_start2
 56/197 Test  #56: braces_nested_start2 ......................   Passed    0.03 sec
        Start  57: braces_nested_start3
 57/197 Test  #57: braces_nested_start3 ......................   Passed    0.03 sec
        Start  58: braces_nested_start4
 58/197 Test  #58: braces_nested_start4 ......................   Passed    0.03 sec
        Start  59: braces_nested_start5
 59/197 Test  #59: braces_nested_start5 ......................   Passed    0.03 sec
        Start  60: braces_nested_end1
 60/197 Test  #60: braces_nested_end1 ........................   Passed    0.03 sec
        Start  61: braces_nested_end2
 61/197 Test  #61: braces_nested_end2 ........................   Passed    0.03 sec
        Start  62: braces_nested_end3
 62/197 Test  #62: braces_nested_end3 ........................   Passed    0.03 sec
        Start  63: braces_nested_end4
 63/197 Test  #63: braces_nested_end4 ........................   Passed    0.03 sec
        Start  64: braces_nested_end5
 64/197 Test  #64: braces_nested_end5 ........................   Passed    0.03 sec
        Start  65: braces_closing_in_beginning
 65/197 Test  #65: braces_closing_in_beginning ...............   Passed    0.03 sec
        Start  66: braces_unmatched1
 66/197 Test  #66: braces_unmatched1 .........................   Passed    0.03 sec
        Start  67: braces_unmatched2
 67/197 Test  #67: braces_unmatched2 .........................   Passed    0.03 sec
        Start  68: braces_unmatched3
 68/197 Test  #68: braces_unmatched3 .........................   Passed    0.03 sec
        Start  69: braces_unmatched4
 69/197 Test  #69: braces_unmatched4 .........................   Passed    0.03 sec
        Start  70: braces_unmatched5
 70/197 Test  #70: braces_unmatched5 .........................   Passed    0.03 sec
        Start  71: braces_escaped_comma1
 71/197 Test  #71: braces_escaped_comma1 .....................   Passed    0.03 sec
        Start  72: braces_escaped_comma2
 72/197 Test  #72: braces_escaped_comma2 .....................   Passed    0.03 sec
        Start  73: braces_escaped_comma3
 73/197 Test  #73: braces_escaped_comma3 .....................   Passed    0.03 sec
        Start  74: braces_escaped_brace1
 74/197 Test  #74: braces_escaped_brace1 .....................   Passed    0.03 sec
        Start  75: braces_escaped_brace2
 75/197 Test  #75: braces_escaped_brace2 .....................   Passed    0.03 sec
        Start  76: braces_escaped_brace3
 76/197 Test  #76: braces_escaped_brace3 .....................   Passed    0.03 sec
        Start  77: braces_escaped_backslash1
 77/197 Test  #77: braces_escaped_backslash1 .................   Passed    0.03 sec
        Start  78: braces_escaped_backslash2
 78/197 Test  #78: braces_escaped_backslash2 .................   Passed    0.03 sec
        Start  79: braces_escaped_backslash3
 79/197 Test  #79: braces_escaped_backslash3 .................   Passed    0.03 sec
        Start  80: braces_patterns_nested1
 80/197 Test  #80: braces_patterns_nested1 ...................   Passed    0.03 sec
        Start  81: braces_patterns_nested2
 81/197 Test  #81: braces_patterns_nested2 ...................   Passed    0.03 sec
        Start  82: braces_patterns_nested3
 82/197 Test  #82: braces_patterns_nested3 ...................   Passed    0.03 sec
        Start  83: braces_patterns_nested4
 83/197 Test  #83: braces_patterns_nested4 ...................   Passed    0.03 sec
        Start  84: braces_patterns_nested5
 84/197 Test  #84: braces_patterns_nested5 ...................   Passed    0.03 sec
        Start  85: braces_patterns_nested6
 85/197 Test  #85: braces_patterns_nested6 ...................   Passed    0.03 sec
        Start  86: braces_patterns_nested7
 86/197 Test  #86: braces_patterns_nested7 ...................   Passed    0.03 sec
        Start  87: braces_patterns_nested8
 87/197 Test  #87: braces_patterns_nested8 ...................   Passed    0.03 sec
        Start  88: braces_patterns_nested9
 88/197 Test  #88: braces_patterns_nested9 ...................   Passed    0.03 sec
        Start  89: braces_patterns_nested10
 89/197 Test  #89: braces_patterns_nested10 ..................   Passed    0.03 sec
        Start  90: braces_patterns_nested11
 90/197 Test  #90: braces_patterns_nested11 ..................   Passed    0.03 sec
        Start  91: braces_patterns_nested12
 91/197 Test  #91: braces_patterns_nested12 ..................   Passed    0.03 sec
        Start  92: braces_numeric_range1
 92/197 Test  #92: braces_numeric_range1 .....................   Passed    0.03 sec
        Start  93: braces_numeric_range2
 93/197 Test  #93: braces_numeric_range2 .....................   Passed    0.03 sec
        Start  94: braces_numeric_range3
 94/197 Test  #94: braces_numeric_range3 .....................   Passed    0.03 sec
        Start  95: braces_numeric_range4
 95/197 Test  #95: braces_numeric_range4 .....................   Passed    0.03 sec
        Start  96: braces_numeric_range5
 96/197 Test  #96: braces_numeric_range5 .....................   Passed    0.03 sec
        Start  97: braces_numeric_range6
 97/197 Test  #97: braces_numeric_range6 .....................   Passed    0.03 sec
        Start  98: braces_numeric_range7
 98/197 Test  #98: braces_numeric_range7 .....................   Passed    0.03 sec
        Start  99: braces_numeric_range8
 99/197 Test  #99: braces_numeric_range8 .....................   Passed    0.03 sec
        Start 100: braces_alpha_range1
100/197 Test #100: braces_alpha_range1 .......................   Passed    0.03 sec
        Start 101: braces_alpha_range2
101/197 Test #101: braces_alpha_range2 .......................   Passed    0.03 sec
        Start 102: braces_alpha_range3
102/197 Test #102: braces_alpha_range3 .......................   Passed    0.03 sec
        Start 103: braces_alpha_range4
103/197 Test #103: braces_alpha_range4 .......................   Passed    0.03 sec
        Start 104: braces_alpha_range5
104/197 Test #104: braces_alpha_range5 .......................   Passed    0.03 sec
        Start 105: braces_alpha_range6
105/197 Test #105: braces_alpha_range6 .......................   Passed    0.03 sec
        Start 106: utf_8_char
106/197 Test #106: utf_8_char ................................   Passed    0.03 sec
        Start 107: star_star_over_separator1
107/197 Test #107: star_star_over_separator1 .................   Passed    0.03 sec
        Start 108: star_star_over_separator2
108/197 Test #108: star_star_over_separator2 .................   Passed    0.03 sec
        Start 109: star_star_over_separator3
109/197 Test #109: star_star_over_separator3 .................   Passed    0.03 sec
        Start 110: star_star_over_separator4
110/197 Test #110: star_star_over_separator4 .................   Passed    0.03 sec
        Start 111: star_star_over_separator5
111/197 Test #111: star_star_over_separator5 .................   Passed    0.03 sec
        Start 112: star_star_over_separator6
112/197 Test #112: star_star_over_separator6 .................   Passed    0.03 sec
        Start 113: star_star_over_separator7
113/197 Test #113: star_star_over_separator7 .................   Passed    0.03 sec
        Start 114: star_star_over_separator8
114/197 Test #114: star_star_over_separator8 .................   Passed    0.03 sec
        Start 115: star_star_over_separator9
115/197 Test #115: star_star_over_separator9 .................   Passed    0.03 sec
        Start 116: star_star_over_separator10
116/197 Test #116: star_star_over_separator10 ................   Passed    0.03 sec
        Start 117: star_star_over_separator11
117/197 Test #117: star_star_over_separator11 ................   Passed    0.03 sec
        Start 118: star_star_over_separator12
118/197 Test #118: star_star_over_separator12 ................   Passed    0.03 sec
        Start 119: star_star_over_separator13
119/197 Test #119: star_star_over_separator13 ................   Passed    0.03 sec
        Start 120: star_star_over_separator14
120/197 Test #120: star_star_over_separator14 ................   Passed    0.03 sec
        Start 121: star_star_over_separator15
121/197 Test #121: star_star_over_separator15 ................   Passed    0.03 sec
        Start 122: star_star_over_separator16
122/197 Test #122: star_star_over_separator16 ................   Passed    0.03 sec
        Start 123: star_star_over_separator17
123/197 Test #123: star_star_over_separator17 ................   Passed    0.03 sec
        Start 124: star_star_over_separator18
124/197 Test #124: star_star_over_separator18 ................   Passed    0.03 sec
        Start 125: star_star_over_separator19
125/197 Test #125: star_star_over_separator19 ................   Passed    0.03 sec
        Start 126: star_star_over_separator20
126/197 Test #126: star_star_over_separator20 ................   Passed    0.03 sec
        Start 127: star_star_over_separator21
127/197 Test #127: star_star_over_separator21 ................   Passed    0.03 sec
        Start 128: star_star_over_separator22
128/197 Test #128: star_star_over_separator22 ................   Passed    0.03 sec
        Start 129: star_star_over_separator23
129/197 Test #129: star_star_over_separator23 ................   Passed    0.03 sec
        Start 130: star_star_over_separator24
130/197 Test #130: star_star_over_separator24 ................   Passed    0.03 sec
        Start 131: tab_width_default_ML
131/197 Test #131: tab_width_default_ML ......................   Passed    0.03 sec
        Start 132: tab_width_default_indent_size_tab_ML
132/197 Test #132: tab_width_default_indent_size_tab_ML ......   Passed    0.03 sec
        Start 133: indent_size_default_ML
133/197 Test #133: indent_size_default_ML ....................   Passed    0.03 sec
        Start 134: indent_size_default_pre_0_9_0
134/197 Test #134: indent_size_default_pre_0_9_0 .............   Passed    0.03 sec
        Start 135: indent_size_default_space
135/197 Test #135: indent_size_default_space .................   Passed    0.03 sec
        Start 136: indent_size_default_with_tab_width_ML
136/197 Test #136: indent_size_default_with_tab_width_ML .....   Passed    0.03 sec
        Start 137: lowercase_values1_ML
137/197 Test #137: lowercase_values1_ML ......................   Passed    0.03 sec
        Start 138: lowercase_values2_ML
138/197 Test #138: lowercase_values2_ML ......................   Passed    0.03 sec
        Start 139: lowercase_values3
139/197 Test #139: lowercase_values3 .........................   Passed    0.03 sec
        Start 140: lowercase_names
140/197 Test #140: lowercase_names ...........................   Passed    0.03 sec
        Start 141: repeat_sections_ML
141/197 Test #141: repeat_sections_ML ........................   Passed    0.03 sec
        Start 142: basic_cascade_ML
142/197 Test #142: basic_cascade_ML ..........................   Passed    0.03 sec
        Start 143: no_whitespace
143/197 Test #143: no_whitespace .............................   Passed    0.03 sec
        Start 144: single_spaces_around_equals
144/197 Test #144: single_spaces_around_equals ...............   Passed    0.03 sec
        Start 145: multiple_spaces_around_equals
145/197 Test #145: multiple_spaces_around_equals .............   Passed    0.03 sec
        Start 146: spaces_before_property_name
146/197 Test #146: spaces_before_property_name ...............   Passed    0.03 sec
        Start 147: spaces_after_property_value
147/197 Test #147: spaces_after_property_value ...............   Passed    0.03 sec
        Start 148: blank_lines_between_properties_ML
148/197 Test #148: blank_lines_between_properties_ML .........   Passed    0.03 sec
        Start 149: spaces_in_section_name
149/197 Test #149: spaces_in_section_name ....................   Passed    0.03 sec
        Start 150: spaces_before_section_name
150/197 Test #150: spaces_before_section_name ................   Passed    0.03 sec
        Start 151: spaces_after_section_name
151/197 Test #151: spaces_after_section_name .................   Passed    0.03 sec
        Start 152: spaces_before_middle_property_ML
152/197 Test #152: spaces_before_middle_property_ML ..........   Passed    0.03 sec
        Start 153: comment_before_props
153/197 Test #153: comment_before_props ......................   Passed    0.03 sec
        Start 154: comment_between_props_ML
154/197 Test #154: comment_between_props_ML ..................   Passed    0.03 sec
        Start 155: semicolon_in_property
155/197 Test #155: semicolon_in_property .....................   Passed    0.03 sec
        Start 156: escaped_semicolon_in_section
156/197 Test #156: escaped_semicolon_in_section ..............   Passed    0.03 sec
        Start 157: octothorpe_comment_before_props
157/197 Test #157: octothorpe_comment_before_props ...........   Passed    0.03 sec
        Start 158: octothorpe_comment_between_props_ML
158/197 Test #158: octothorpe_comment_between_props_ML .......   Passed    0.03 sec
        Start 159: octothorpe_in_value
159/197 Test #159: octothorpe_in_value .......................   Passed    0.03 sec
        Start 160: escaped_octothorpe_in_section
160/197 Test #160: escaped_octothorpe_in_section .............   Passed    0.03 sec
        Start 161: bom_at_head
161/197 Test #161: bom_at_head ...............................   Passed    0.03 sec
        Start 162: crlf_linesep
162/197 Test #162: crlf_linesep ..............................   Passed    0.03 sec
        Start 163: max_property_name
163/197 Test #163: max_property_name .........................   Passed    0.03 sec
        Start 164: max_property_value
164/197 Test #164: max_property_value ........................   Passed    0.03 sec
        Start 165: max_section_name_ok
165/197 Test #165: max_section_name_ok .......................   Passed    0.03 sec
        Start 166: max_section_name_ignore
166/197 Test #166: max_section_name_ignore ...................   Passed    0.03 sec
        Start 167: empty_editorconfig_file
167/197 Test #167: empty_editorconfig_file ...................   Passed    0.03 sec
        Start 168: newlines_only_editorconfig_file
168/197 Test #168: newlines_only_editorconfig_file ...........   Passed    0.03 sec
        Start 169: comments_only_editorconfig_file
169/197 Test #169: comments_only_editorconfig_file ...........   Passed    0.03 sec
        Start 170: comments_and_newlines_editorconfig_file
170/197 Test #170: comments_and_newlines_editorconfig_file ...   Passed    0.03 sec
        Start 171: parent_directory
171/197 Test #171: parent_directory ..........................   Passed    0.03 sec
        Start 172: parent_and_current_dir_ML
172/197 Test #172: parent_and_current_dir_ML .................   Passed    0.03 sec
        Start 173: parent_dir_overload
173/197 Test #173: parent_dir_overload .......................   Passed    0.03 sec
        Start 174: parent_dir_overload_repeat
174/197 Test #174: parent_dir_overload_repeat ................   Passed    0.03 sec
        Start 175: parent_dir_overload_repeat2
175/197 Test #175: parent_dir_overload_repeat2 ...............   Passed    0.03 sec
        Start 176: root_file
176/197 Test #176: root_file .................................   Passed    0.03 sec
        Start 177: root_file_mixed_case
177/197 Test #177: root_file_mixed_case ......................   Passed    0.03 sec
        Start 178: root_pattern
178/197 Test #178: root_pattern ..............................   Passed    0.03 sec
        Start 179: path_separator
179/197 Test #179: path_separator ............................   Passed    0.03 sec
        Start 180: path_separator_backslash_in_cmd_line
180/197 Test #180: path_separator_backslash_in_cmd_line ......   Passed    0.03 sec
        Start 181: nested_path_separator
181/197 Test #181: nested_path_separator .....................   Passed    0.05 sec
        Start 182: top_level_path_separator
182/197 Test #182: top_level_path_separator ..................   Passed    0.03 sec
        Start 183: top_level_path_separator_neg
183/197 Test #183: top_level_path_separator_neg ..............   Passed    0.03 sec
        Start 184: windows_separator
184/197 Test #184: windows_separator .........................   Passed    0.03 sec
        Start 185: windows_separator2
185/197 Test #185: windows_separator2 ........................   Passed    0.03 sec
        Start 186: backslash_not_on_windows
186/197 Test #186: backslash_not_on_windows ..................   Passed    0.03 sec
        Start 187: path_with_special_chars
187/197 Test #187: path_with_special_chars ...................   Passed    0.03 sec
        Start 188: unset_charset
188/197 Test #188: unset_charset .............................   Passed    0.03 sec
        Start 189: unset_end_of_line
189/197 Test #189: unset_end_of_line .........................   Passed    0.03 sec
        Start 190: unset_indent_size_ML
190/197 Test #190: unset_indent_size_ML ......................   Passed    0.03 sec
        Start 191: unset_indent_style
191/197 Test #191: unset_indent_style ........................   Passed    0.03 sec
        Start 192: unset_insert_final_newline
192/197 Test #192: unset_insert_final_newline ................   Passed    0.03 sec
        Start 193: unset_tab_width
193/197 Test #193: unset_tab_width ...........................   Passed    0.03 sec
        Start 194: unset_trim_trailing_whitespace
194/197 Test #194: unset_trim_trailing_whitespace ............   Passed    0.03 sec
        Start 195: test_long_version_switch
195/197 Test #195: test_long_version_switch ..................   Passed    0.03 sec
        Start 196: test_short_version_switch
196/197 Test #196: test_short_version_switch .................   Passed    0.03 sec
        Start 197: multiple_files_on_command_line
197/197 Test #197: multiple_files_on_command_line ............   Passed    0.03 sec

100% tests passed, 0 tests failed out of 197

Total Test time (real) =   5.57 sec