Skip to content

Commit

Permalink
fix: couple of code tunings to align alpha with main branch ( minus g…
Browse files Browse the repository at this point in the history
…olang)

Signed-off-by: Zvi Grinberg <[email protected]>
  • Loading branch information
zvigrinberg committed Sep 7, 2023
1 parent eb4da0d commit 118139e
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 15 deletions.
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,7 @@
"dependencies": {
"@cyclonedx/cyclonedx-library": "^4.0.0",
"fast-xml-parser": "^4.2.4",
"get-root-path": "^2.0.2",
"packageurl-js": "^1.0.2",
"properties-reader": "^2.3.0",
"yargs": "^17.7.2"
},
"devDependencies": {
Expand Down
4 changes: 0 additions & 4 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
import {rootPath} from "get-root-path";
import { availableProviders, match } from './provider.js'
import {AnalysisReport} from '../generated/backend/AnalysisReport.js'
import analysis from './analysis.js'
import fs from 'node:fs'
import {getCustom} from "./tools.js";
import path from 'node:path'

import PropertiesReader from 'properties-reader'

export default { AnalysisReport, componentAnalysis, stackAnalysis, validateToken }

Expand Down
11 changes: 2 additions & 9 deletions test/get-exhort-url.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { expect } from 'chai'
import {exhortDefaultUrl, exhortDevDefaultUrl, testSelectExhortBackend,properties} from "../src/index.js"
import {exhortDefaultUrl, exhortDevDefaultUrl, testSelectExhortBackend} from "../src/index.js"

suite('testing Select Exhort Backend function when EXHORT_DEV_MODE environment variable is True', () => {

Expand Down Expand Up @@ -108,14 +108,7 @@ suite('testing Select Exhort Backend function when EXHORT_DEV_MODE environment v

test('When Nothing set, Choose default backend (production) ', () => {
let selectedUrl = testSelectExhortBackend({});
if(properties.get("EXHORT_DEV_MODE").toString().trim() === "false" )
{
expect(selectedUrl).to.be.equals(exhortDefaultUrl)
}
else
{
expect(true).to.be.true
}
expect(selectedUrl).to.be.equals(exhortDefaultUrl)
});


Expand Down

0 comments on commit 118139e

Please sign in to comment.