Skip to content

Commit d8dbdfc

Browse files
Jami CogswellJami Cogswell
authored andcommitted
rename expected file, add ql file, delete qlref file
1 parent 8c4b98c commit d8dbdfc

File tree

4 files changed

+22
-2
lines changed

4 files changed

+22
-2
lines changed

java/ql/test/query-tests/security/CWE-489/DebuggableAttributeEnabledTest.expected

Whitespace-only changes.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import java
2+
import semmle.code.xml.AndroidManifest
3+
import TestUtilities.InlineExpectationsTest
4+
5+
class DebuggableAttributeTrueTest extends InlineExpectationsTest {
6+
DebuggableAttributeTrueTest() { this = "DebuggableAttributeEnabledTest" }
7+
8+
override string getARelevantTag() { result = "hasDebuggableAttributeEnabled" }
9+
10+
override predicate hasActualResult(Location location, string element, string tag, string value) {
11+
tag = "hasDebuggableAttributeEnabled" and
12+
exists(AndroidXmlAttribute androidXmlAttr |
13+
androidXmlAttr.getName() = "debuggable" and
14+
androidXmlAttr.getValue() = "true" and
15+
not androidXmlAttr.getLocation().getFile().getRelativePath().matches("%/build%")
16+
|
17+
androidXmlAttr.getLocation() = location and
18+
element = androidXmlAttr.toString() and
19+
value = ""
20+
)
21+
}
22+
}

java/ql/test/query-tests/security/CWE-489/DebuggableAttributeTrue.expected

Lines changed: 0 additions & 1 deletion
This file was deleted.

java/ql/test/query-tests/security/CWE-489/DebuggableAttributeTrue.qlref

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)