Skip to content
Merged
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/metadata_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,14 @@ func TestShouldSyncMetadata(t *testing.T) {
}
}

// TestShouldRestoreMetadata tests the shouldRestoreMetadata function of the AlluxioEngine.
// It creates a set of test datasets and initializes a fake client with these datasets.
// Then, it creates two AlluxioEngine instances with different configurations and checks
// if the shouldRestoreMetadata function returns the expected results for each instance.
// The test cases include:
// - An engine with a dataset that has a DataRestoreLocation specified, expecting shouldRestoreMetadata to return true.
// - An engine with a dataset that does not have a DataRestoreLocation specified, expecting shouldRestoreMetadata to return false.
// If the function does not return the expected result or an error occurs, the test will fail.
func TestShouldRestoreMetadata(t *testing.T) {
datasetInputs := []datav1alpha1.Dataset{
{
Expand Down
Loading