-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e4a96a9
commit 4d4e49a
Showing
6 changed files
with
45 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,6 +47,7 @@ jobs: | |
mv workspace/thorat.zip thorat.zip | ||
mv workspace/defects4j.zip defects4j.zip | ||
mv workspace/bugs_in_py.zip bugs_in_py.zip | ||
mv workspace/securibench-micro-js.zip securibench-micro-js.zip | ||
- name: Set next release version | ||
id: taggerFinal | ||
uses: anothrNick/[email protected] | ||
|
@@ -63,4 +64,5 @@ jobs: | |
securibench-micro-JAVASRC.zip | ||
thorat.zip | ||
defects4j.zip | ||
bugs_in_py.zip | ||
bugs_in_py.zip | ||
securibench-micro-js.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
src/main/scala/io/joern/benchmarks/datasets/runner/SecuribenchMicroJsDownloader.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
package io.joern.benchmarks.datasets.runner | ||
|
||
import better.files.File | ||
import io.joern.benchmarks.* | ||
import io.joern.benchmarks.datasets.JavaCpgTypes | ||
import org.slf4j.LoggerFactory | ||
|
||
import java.net.{URI, URL} | ||
import scala.util.{Failure, Success, Try} | ||
|
||
class SecuribenchMicroJsDownloader(datasetDir: File) extends DatasetDownloader(datasetDir) with SingleFileDownloader { | ||
|
||
private val logger = LoggerFactory.getLogger(getClass) | ||
|
||
override val benchmarkName = s"securibench-micro.js v1.0.0" | ||
|
||
override protected val benchmarkUrl: URL = URI( | ||
"https://github.com/DavidBakerEffendi/securibench-micro.js/archive/refs/tags/v1.0.0.zip" | ||
).toURL | ||
override protected val benchmarkFileName: String = "securibench-micro.js-1.0.0" | ||
override protected val benchmarkBaseDir: File = datasetDir / benchmarkFileName | ||
|
||
override def initialize(): Try[File] = { | ||
val target = datasetDir / "securibench-micro-js.zip" | ||
if !target.exists then downloadFile(benchmarkUrl, datasetDir / "securibench-micro-js.zip") | ||
else Success(target) | ||
} | ||
|
||
override def run(): Unit = { | ||
initialize() match { | ||
case Failure(exception) => | ||
logger.error(s"Unable to initialize benchmark '$getClass'", exception) | ||
case Success(_) => | ||
} | ||
} | ||
} |