Skip to content

Refactor pkg names for 'revive' linter error#86

Merged
santhoshatdell merged 2 commits into
mainfrom
fix-pkg-names
Jul 18, 2025
Merged

Refactor pkg names for 'revive' linter error#86
santhoshatdell merged 2 commits into
mainfrom
fix-pkg-names

Conversation

@santhoshatdell

@santhoshatdell santhoshatdell commented Jul 15, 2025

Copy link
Copy Markdown

Description

This PR addresses the package name errors reported by revive linter.

GitHub Issues

List the GitHub issues impacted by this PR:

GitHub Issue #
https://github.com/dell/csm/issues/1896

Checklist:

  • I have performed a self-review of my own code to ensure there are no formatting, vetting, linting, or security issues
  • I have verified that new and existing unit tests pass locally with my changes
  • I have not allowed coverage numbers to degenerate
  • I have maintained at least 90% code coverage
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • Backward compatibility is not broken

How Has This Been Tested?

  • Built csi-powerflex driver with this commit ID.
  • Ran cert-csi tests and it passed.
[root@master-1-gMLffggcEYiL6 cert-csi]# ./cert-csi certify --cert-config powerflex-config.yaml --vsc vxflexos-snapclass
[2025-07-17 16:10:56]  INFO Starting cert-csi; ver. 1.8.0
.....
[2025-07-17 16:10:56]  INFO Suites to run with vxflexos storage class:
[2025-07-17 16:10:56]  INFO 1. VolumeIoSuite {volumes: 2, volumeSize: 8Gi chains: 2-2}
[2025-07-17 16:10:56]  INFO 2. ScalingSuite {replicas: 2, volumes: 5, volumeSize: 8Gi}
[2025-07-17 16:10:56]  INFO 3. CloneVolumeSuite {pods: 2, volumes: 1, volumeSize: 8Gi}
[2025-07-17 16:10:56]  INFO 4. VolumeExpansionSuite {pods: 1, volumes: 1, size: 8Gi, expSize: 16Gi, block: false}
[2025-07-17 16:10:56]  INFO 5. VolumeExpansionSuite {pods: 1, volumes: 1, size: 8Gi, expSize: 16Gi, block: true}
[2025-07-17 16:10:56]  INFO 6. SnapSuite {snapshots: 3, volumeSize; 8Gi}
[2025-07-17 16:10:56]  INFO 7. ReplicationSuite {pods: 2, volumes: 5, volumeSize: 8Gi}
[2025-07-17 16:10:56]  INFO 8. MultiAttachSuite {pods: 5, rawBlock: true, size: 8Gi, accMode: ReadWriteMany}
[2025-07-17 16:10:56]  INFO 9. EphemeralVolumeSuite {driver: csi-vxflexos.dellemc.com, podNumber: 2, volAttributes: map[size:8Gi storagepool:SP1 systemID:<ID> volumeName:my-ephemeral-vol]}
Does it look OK? (Y)es/(n)o
-> Y
[2025-07-17 16:13:56]  INFO Avg time of a run:   84.83s
[2025-07-17 16:13:56]  INFO Avg time of a del:   23.28s
[2025-07-17 16:13:56]  INFO Avg time of all:     110.31s
[2025-07-17 16:13:56]  INFO During this run 100.0% of suites succeeded

@santhoshatdell santhoshatdell marked this pull request as ready for review July 17, 2025 21:21
@santhoshatdell

Copy link
Copy Markdown
Author

The renamed 'interface' only class has to be excluded from the package coverage, for the workflow action to pass.

@github-actions

Copy link
Copy Markdown

Merging this branch will increase overall coverage

Impacted Packages Coverage Δ 🤖
github.com/dell/gocsi 90.06% (ø)
github.com/dell/gocsi/csc/cmd 92.20% (ø)
github.com/dell/gocsi/middleware/logging 100.00% (ø)
github.com/dell/gocsi/middleware/serialvolume 91.86% (ø)
github.com/dell/gocsi/middleware/serialvolume/etcd 90.55% (ø)
github.com/dell/gocsi/middleware/serialvolume/lockprovider 0.00% (ø)
github.com/dell/gocsi/middleware/specvalidator 91.29% (ø)
github.com/dell/gocsi/mock/service 0.00% (ø)
github.com/dell/gocsi/testing 0.00% (ø)
github.com/dell/gocsi/utils/csi 90.31% (+90.31%) 🌟
github.com/dell/gocsi/utils/middleware 100.00% (+100.00%) 🌟
github.com/dell/gocsi/utils/rpcs 100.00% (+100.00%) 🌟

Coverage by file

Changed files (no unit tests)

Changed File Coverage Δ Total Covered Missed 🤖
github.com/dell/gocsi/csc/cmd/controller_list_snapshots.go 92.00% (ø) 25 23 2
github.com/dell/gocsi/csc/cmd/controller_list_volumes.go 86.96% (ø) 23 20 3
github.com/dell/gocsi/csc/cmd/interceptors.go 53.57% (ø) 28 15 13
github.com/dell/gocsi/csc/cmd/root.go 80.26% (ø) 76 61 15
github.com/dell/gocsi/envvars.go 84.85% (ø) 33 28 5
github.com/dell/gocsi/gocsi.go 86.93% (ø) 199 173 26
github.com/dell/gocsi/middleware.go 98.00% (ø) 100 98 2
github.com/dell/gocsi/middleware/logging/logging_interceptor.go 100.00% (ø) 68 68 0
github.com/dell/gocsi/middleware/serialvolume/etcd/etcd_lock_provider.go 90.55% (ø) 127 115 12
github.com/dell/gocsi/middleware/serialvolume/lockprovider/volume_lock_provider.go 0.00% (ø) 0 0 0
github.com/dell/gocsi/middleware/serialvolume/serial_volume_locker.go 90.28% (ø) 72 65 7
github.com/dell/gocsi/middleware/specvalidator/spec_validator.go 91.29% (ø) 264 241 23
github.com/dell/gocsi/mock/service/controller.go 0.00% (ø) 0 0 0
github.com/dell/gocsi/mock/service/service.go 0.00% (ø) 0 0 0
github.com/dell/gocsi/utils/csi/csi.go 90.31% (+90.31%) 227 (+227) 205 (+205) 22 (+22) 🌟
github.com/dell/gocsi/utils/middleware/middleware.go 100.00% (+100.00%) 30 (+30) 30 (+30) 0 🌟
github.com/dell/gocsi/utils/rpcs/rpcs.go 100.00% (+100.00%) 8 (+8) 8 (+8) 0 🌟

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/dell/gocsi/csc/cmd/controller_test.go
  • github.com/dell/gocsi/middleware/serialvolume/etcd/etcd_lock_provider_test.go
  • github.com/dell/gocsi/middleware/serialvolume/lockprovider/volume_lock_provider_test.go
  • github.com/dell/gocsi/testing/controller_test.go
  • github.com/dell/gocsi/testing/node_test.go
  • github.com/dell/gocsi/utils/csi/csi_suite_test.go
  • github.com/dell/gocsi/utils/csi/csi_test.go
  • github.com/dell/gocsi/utils/middleware/middleware_test.go
  • github.com/dell/gocsi/utils/rpcs/rpcs_test.go

@santhoshatdell santhoshatdell merged commit 54c2b32 into main Jul 18, 2025
11 of 12 checks passed
@santhoshatdell santhoshatdell deleted the fix-pkg-names branch July 18, 2025 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants