Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions pkg/ddc/alluxio/operations/base_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,15 @@ func TestAlluxioFIleUtils_Mount(t *testing.T) {
}
}

// TestAlluxioFileUtils_IsMounted tests the IsMounted method of AlluxioFileUtils.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Content is accurate, and formatting-wise this version is actually the cleanest of the three attempts: the blank line before the doc comment is preserved, and the bullets use Go's idiomatic doc-list indent (three-space - item with hanging continuation on the wrap). Worth flagging though: #6016 (fixing the same issue #6015) and #6014 have been open since 2026-06-16 and add essentially the same comment on the same function. Are you aware of that overlap? Only one of these can land, so it would help to coordinate with @Sovestkiy — either here or on #6016 — on which to keep. For reference, #6016 drops the blank line between the previous function's closing brace and the new doc, which is why this one reads more naturally to me.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the review @cheyang! I wasn't aware of the overlap with #6016 and #6014. Since you mentioned this PR reads more naturally due to the preserved blank line and uses Go's idiomatic doc-list indent correctly, I'd recommend merging this one and closing the others. I've reached out to @Sovestkiy to coordinate.

// It verifies the method's ability to correctly determine whether a given Alluxio
// path is mounted by parsing the output of the underlying alluxio fs mount command.
//
// Test cases:
// - ExecErr: Tests handling of command execution errors, ensuring an error is
// returned when the exec command fails.
// - /spark: Tests a non-existent mount path, expecting false.
// - /hbase: Tests an existing mount path, expecting true.
func TestAlluxioFileUtils_IsMounted(t *testing.T) {
ExecCommon := func(a AlluxioFileUtils, command []string, verbose bool) (stdout string, stderr string, err error) {
return "https://mirrors.bit.edu.cn/apache/hbase/stable on /hbase (web, capacity=-1B, used=-1B, read-only, not shared, properties={}) \n /underFSStorage on / (local, capacity=0B, used=0B, not read-only, not shared, properties={})", "", nil
Expand Down
Loading