summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authormo khan <mo.khan@gmail.com>2020-11-08 16:29:29 -0700
committermo khan <mo.khan@gmail.com>2020-11-08 16:29:29 -0700
commite2fd48f6c9b8716ded9075077a0159fc44fdbb94 (patch)
tree5b76d680153ec5480eab6d98d020c76441ffd093 /lib
parent3243a7a3ae63d3bbad4b3a8e1d78720a0e54f198 (diff)
test: add tests for matching apk installed file
Diffstat (limited to 'lib')
-rw-r--r--lib/spandx/os/parsers/apk.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/spandx/os/parsers/apk.rb b/lib/spandx/os/parsers/apk.rb
index ede9367..4548403 100644
--- a/lib/spandx/os/parsers/apk.rb
+++ b/lib/spandx/os/parsers/apk.rb
@@ -4,6 +4,10 @@ module Spandx
module Os
module Parsers
class Apk < ::Spandx::Core::Parser
+ def match?(path)
+ path.basename.fnmatch?('installed')
+ end
+
def parse(lockfile)
path = lockfile.to_s