mirror of
https://github.com/shadow1ng/fscan.git
synced 2026-09-26 05:01:53 +08:00
move plugin safety metadata to registry
This commit is contained in:
@@ -111,6 +111,16 @@ func TestListPlugins(t *testing.T) {
|
||||
if _, ok := GetPlugin("definitely-missing"); ok {
|
||||
t.Fatal("unknown plugin should not exist")
|
||||
}
|
||||
webpoc, ok := GetPlugin("webpoc")
|
||||
if !ok {
|
||||
t.Fatal("missing webpoc plugin")
|
||||
}
|
||||
if webpoc.Safe {
|
||||
t.Fatal("webpoc should be marked unsafe")
|
||||
}
|
||||
if !containsString(webpoc.Types, PluginTypeWeb) {
|
||||
t.Fatalf("webpoc types = %#v, want web", webpoc.Types)
|
||||
}
|
||||
}
|
||||
|
||||
func TestScanHonorsCanceledContext(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user