Skip to content

This PR is to add comments to TestUpdateDatasetStatus in pkg\ddc\alluxio\dataset_test.go #4982

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

Closed
Closed
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
8 changes: 8 additions & 0 deletions pkg/ddc/alluxio/dataset_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,14 @@ func TestUpdateCacheOfDataset(t *testing.T) {
}
}

// TestUpdateDatasetStatus tests the functionality of UpdateDatasetStatus method in AlluxioEngine.
// This test creates mock Dataset and AlluxioRuntime objects, and verifies that:
// 1. The Dataset status is correctly updated according to the provided phase parameter
// 2. Cache states from the runtime are properly propagated to the Dataset
// 3. HCFS status information is preserved during updates
// 4. Runtime information is correctly added to Dataset status when in BoundDatasetPhase
// The test cycles through three phases: BoundDatasetPhase, FailedDatasetPhase, and NoneDatasetPhase,
// validating the expected results for each case.
func TestUpdateDatasetStatus(t *testing.T) {
testDatasetInputs := []*datav1alpha1.Dataset{
{
Expand Down
Loading