Skip to content

Commit

Permalink
Fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
jporzucek committed Aug 26, 2023
1 parent 916bae7 commit 7e42754
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 67 deletions.
12 changes: 6 additions & 6 deletions github/code-scanning.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ type MostRecentInstance struct {
CommitSHA *string `json:"commit_sha,omitempty"`
Message *Message `json:"message,omitempty"`
Location *Location `json:"location,omitempty"`
HtmlUrl *string `json:"html_url,omitempty"`
HTMLURL *string `json:"html_url,omitempty"`
Classifications []string `json:"classifications,omitempty"`
}

Expand Down Expand Up @@ -162,15 +162,15 @@ type AnalysesListOptions struct {
//
// GitHub API docs: https://docs.github.com/en/rest/code-scanning
type CodeqlDatabase struct {
Id *int64 `json:"id,omitempty"`
ID *int64 `json:"id,omitempty"`
Name *string `json:"name,omitempty"`
Language *string `json:"language,omitempty"`
Uploader *User `json:"uploader,omitempty"`
ContentType *string `json:"content_type,omitempty"`
Size *int64 `json:"size,omitempty"`
CreatedAt *Timestamp `json:"created_at,omitempty"`
UpdatedAt *Timestamp `json:"updated_at,omitempty"`
Url *string `json:"url,omitempty"`
URL *string `json:"url,omitempty"`
}

// ScanningAnalysis represents an individual GitHub Code Scanning ScanningAnalysis on a single repository.
Expand Down Expand Up @@ -392,7 +392,7 @@ type SarifUpload struct {
// `failed` files have either not been processed at all, or could only be partially processed.
ProcessingStatus *string `json:"processing_status,omitempty"`
// The REST API URL for getting the analyses associated with the upload.
AnalysesUrl *string `json:"analyses_url,omitempty"`
AnalysesURL *string `json:"analyses_url,omitempty"`
}

// GetSarif get information about a SARIF upload.
Expand Down Expand Up @@ -474,9 +474,9 @@ func (s *CodeScanningService) GetAnalysis(ctx context.Context, owner, repo strin
// DeleteAnalysis represents a successful deletion of a code scanning analysis
type DeleteAnalysis struct {
// Next deletable analysis in chain, without last analysis deletion confirmation
NextAnalysisUrl *string `json:"next_analysis_url,omitempty"`
NextAnalysisURL *string `json:"next_analysis_url,omitempty"`
// Next deletable analysis in chain, with last analysis deletion confirmation
ConfirmDeleteUrl *string `json:"confirm_delete_url,omitempty"`
ConfirmDeleteURL *string `json:"confirm_delete_url,omitempty"`
}

// DeleteAnalysis deletes a single code scanning analysis from a repository.
Expand Down
14 changes: 7 additions & 7 deletions github/code-scanning_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ func TestCodeScanningService_GetSarif(t *testing.T) {

want := &SarifUpload{
ProcessingStatus: String("s"),
AnalysesUrl: String("u"),
AnalysesURL: String("u"),
}
if !cmp.Equal(sarifUpload, want) {
t.Errorf("CodeScanning.GetSarif returned %+v, want %+v", sarifUpload, want)
Expand Down Expand Up @@ -1319,8 +1319,8 @@ func TestCodeScanningService_DeleteAnalysis(t *testing.T) {
}

want := &DeleteAnalysis{
NextAnalysisUrl: String("a"),
ConfirmDeleteUrl: String("b"),
NextAnalysisURL: String("a"),
ConfirmDeleteURL: String("b"),
}
if !cmp.Equal(analysis, want) {
t.Errorf("CodeScanning.DeleteAnalysis returned %+v, want %+v", analysis, want)
Expand Down Expand Up @@ -1390,7 +1390,7 @@ func TestCodeScanningService_ListCodeqlDatabases(t *testing.T) {
date := &Timestamp{time.Date(2021, time.January, 13, 11, 55, 49, 0, time.UTC)}
want := []*CodeqlDatabase{
{
Id: Int64(1),
ID: Int64(1),
Name: String("name"),
Language: String("language"),
Uploader: &User{
Expand All @@ -1417,7 +1417,7 @@ func TestCodeScanningService_ListCodeqlDatabases(t *testing.T) {
Size: Int64(1024),
CreatedAt: date,
UpdatedAt: date,
Url: String("s"),
URL: String("s"),
},
}

Expand Down Expand Up @@ -1486,7 +1486,7 @@ func TestCodeScanningService_GetCodeqlDatabase(t *testing.T) {

date := &Timestamp{time.Date(2021, time.January, 13, 11, 55, 49, 0, time.UTC)}
want := &CodeqlDatabase{
Id: Int64(1),
ID: Int64(1),
Name: String("name"),
Language: String("language"),
Uploader: &User{
Expand All @@ -1513,7 +1513,7 @@ func TestCodeScanningService_GetCodeqlDatabase(t *testing.T) {
Size: Int64(1024),
CreatedAt: date,
UpdatedAt: date,
Url: String("s"),
URL: String("s"),
}

if !cmp.Equal(database, want) {
Expand Down
48 changes: 24 additions & 24 deletions github/github-accessors.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

60 changes: 30 additions & 30 deletions github/github-accessors_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7e42754

Please sign in to comment.