Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MetaData service support #1227

Closed
wants to merge 96 commits into from
Closed

Add MetaData service support #1227

wants to merge 96 commits into from

Conversation

osaidwtd
Copy link

  • All tests passed. If this feature is not already covered by the tests, I added new tests.
  • All static analysis checks passed.
  • This pull request is on the dev branch.
  • I used gofmt for formatting the code before submitting the pull request.

omerzi and others added 30 commits April 5, 2023 10:15
* Improve UI for scan command (jfrog#706)

* Upgrade go version in go.mod to 1.20 (jfrog#732)

* Fix lint issues found (jfrog#733)

* Config transfer - ensure target not older than source (jfrog#721)

* Update tests environment - nuget and dotnet to version 6  (jfrog#734)

* Flatten audit graph (jfrog#736)

* Use gradle-dep-tree with Audit (jfrog#719)

---------

Co-authored-by: Sara Omari <114062096+sarao1310@users.noreply.github.com>
Co-authored-by: Eyal Ben Moshe <eyalbenmoshe@jfrog.com>
Co-authored-by: Michael Sverdlov <sverdlov93@gmail.com>
Co-authored-by: Yahav Itzhak <yahavi@users.noreply.github.com>
# Conflicts:
#	.github/workflows/analysis.yml
#	go.mod
#	go.sum
#	xray/audit/java/gradle.go
#	xray/commands/audit/generic/auditmanager.go
@sverdlov93 sverdlov93 added the new feature Automatically generated release notes label Aug 11, 2024
Comment on lines 65 to 77
func TestCreateMetadataServiceManager(t *testing.T) {
testServer := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
if r.RequestURI == "api/v1/query" {
content := []byte(`{"query":"queryBody"}`)
_, err := w.Write(content)
assert.NoError(t, err)
}
}))
defer testServer.Close()
serviceManager, err := CreateMetadataServiceManager(&config.ServerDetails{MetadataUrl: testServer.URL + "/"}, false)
assert.NoError(t, err)
assert.NotEmpty(t, serviceManager)
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this test doesn't check anything, it just creates a server without calling it. you can just avoid it as this is being tested by the client

@sverdlov93 sverdlov93 changed the base branch from master to dev August 11, 2024 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature Automatically generated release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.