Skip to content
This repository was archived by the owner on Jan 5, 2023. It is now read-only.

Commit 04cec8b

Browse files
authored
Merge pull request #400 from sauyon/autoformat
Autoformat tests
2 parents c7e03cb + 5a9b8a5 commit 04cec8b

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ clean:
3030
DATAFLOW_BRANCH=master
3131

3232
autoformat:
33-
find ql/src -name "*.ql" -or -name "*.qll" | xargs codeql query format -qq -i
33+
find ql -name "*.ql" -or -name "*.qll" | xargs codeql query format -qq -i
3434
git ls-files | grep '\.go$$' | grep -v ^vendor/ | xargs grep -L "//\s*autoformat-ignore" | xargs gofmt -w
3535

3636
check-formatting:
37-
find ql/src -name "*.ql" -or -name "*.qll" | xargs codeql query format --check-only
37+
find ql -name "*.ql" -or -name "*.qll" | xargs codeql query format --check-only
3838
test -z "$$(git ls-files | grep '\.go$$' | grep -v ^vendor/ | xargs grep -L "//\s*autoformat-ignore" | xargs gofmt -l)"
3939

4040
ifeq ($(QHELP_OUT_DIR),)

ql/test/TestUtilities/InlineExpectationsTest.qll

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,9 @@ abstract private class Expectation extends FailureLocatable {
242242

243243
override string toString() { result = comment.toString() }
244244

245-
override predicate hasLocation(string file, int line) { comment.hasLocationInfo(file, line, _, _, _) }
245+
override predicate hasLocation(string file, int line) {
246+
comment.hasLocationInfo(file, line, _, _, _)
247+
}
246248
}
247249

248250
private class ValidExpectation extends Expectation, TValidExpectation {

ql/test/library-tests/semmle/go/GoModExpr/GoModExprs.ql

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,9 @@ predicate repmetadata(Locatable l, string mod, string dep, string dver, string r
6161
)
6262
}
6363

64-
query predicate missingReplace(string mod, string dep, string dver, string rep, string rver, int line) {
64+
query predicate missingReplace(
65+
string mod, string dep, string dver, string rep, string rver, int line
66+
) {
6567
exists(Locatable l | repmetadata(l, mod, dep, dver, rep, rver) |
6668
l.hasLocationInfo(_, line, _, _, _)
6769
) and

0 commit comments

Comments
 (0)