fluid icon indicating copy to clipboard operation
fluid copied to clipboard

Add comments to TestSyncReplicasWithoutWorker in pkg/ddc/alluxio/replicas_test.go

Open wwazure opened this issue 7 months ago • 0 comments

Which function do you want to add comments to?

TestSyncReplicasWithoutWorker in pkg/ddc/alluxio/replicas_test.go

What comments do you want to add?

// TestSyncReplicasWithoutWorker tests the functionality of syncing AlluxioRuntime replicas without Worker.
// This test case verifies whether the SyncReplicas function can correctly update the status of AlluxioRuntime and Dataset
// when there are no Workers available.
// The test case includes the following steps:
// 1. Initialize the test environment, including mock objects for StatefulSet, DaemonSet, AlluxioRuntime, and Dataset.
// 2. Create an AlluxioEngine instance and call the SyncReplicas function.
// 3. Verify that the execution result of the SyncReplicas function meets expectations, including error handling,
//    Runtime status updates, and Dataset status updates.
// The test case expects that without Workers, the Runtime's WorkerPhase should be NotReady, and the Dataset's Phase should be Failed.

wwazure avatar Jun 18 '25 14:06 wwazure