mirror of
https://github.com/polybar/polybar.git
synced 2026-03-07 00:36:56 +00:00
fix(config_parser): Gracefully handle BOM (#2166)
* fix(config_parser): Gracefully handle BOM * Move check to parse_line function And clarify the error message Closes #2075
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
#include "components/config_parser.hpp"
|
||||
|
||||
#include "common/test.hpp"
|
||||
#include "components/logger.hpp"
|
||||
|
||||
@ -98,6 +99,7 @@ TEST_P(ParseLineKeyTest, correctness) {
|
||||
|
||||
TEST_F(ParseLineInValidTest, throwsSyntaxError) {
|
||||
EXPECT_THROW(parser->parse_line("unknown"), syntax_error);
|
||||
EXPECT_THROW(parser->parse_line("\ufeff"), syntax_error);
|
||||
}
|
||||
// }}}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user