Skip to content

Commit 7111f41

Browse files
committed
check-style: ignore comments for currentDatabase() check
Inaccurate, but should OK for check-style scripts. Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
1 parent 922b758 commit 7111f41

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

utils/check-style/check-style

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,9 @@ tables_with_database_column=(
184184
tests_with_database_column=( $(
185185
find $ROOT_PATH/tests/queries -iname '*.sql' -or -iname '*.sh' -or -iname '*.py' -or -iname '*.j2' |
186186
grep -vP $EXCLUDE_DIRS |
187-
xargs grep --with-filename $(printf -- "-e %s " "${tables_with_database_column[@]}") | cut -d: -f1 | sort -u
187+
xargs grep --with-filename $(printf -- "-e %s " "${tables_with_database_column[@]}") |
188+
grep -v -e ':--' -e ':#' |
189+
cut -d: -f1 | sort -u
188190
) )
189191
for test_case in "${tests_with_database_column[@]}"; do
190192
grep -qE database.*currentDatabase "$test_case" || {

0 commit comments

Comments
 (0)