mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
Python: Autoformat query-local libs.
This commit is contained in:
@@ -2,15 +2,14 @@ import python
|
||||
|
||||
/** Whether `mox` or `.StubOutWithMock()` is used in thin module `m`. */
|
||||
predicate useOfMoxInModule(Module m) {
|
||||
exists(ModuleObject mox |
|
||||
mox.getName() = "mox" or mox.getName() = "mox3.mox" |
|
||||
exists(ControlFlowNode use |
|
||||
exists(ModuleObject mox | mox.getName() = "mox" or mox.getName() = "mox3.mox" |
|
||||
exists(ControlFlowNode use |
|
||||
use.refersTo(mox) and
|
||||
use.getScope().getEnclosingModule() = m
|
||||
)
|
||||
)
|
||||
or
|
||||
exists(Call call|
|
||||
exists(Call call |
|
||||
call.getFunc().(Attribute).getName() = "StubOutWithMock" and
|
||||
call.getEnclosingModule() = m
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user