File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -502,6 +502,16 @@ func TestShouldSyncMetadata(t *testing.T) {
502502 }
503503}
504504
505+ /*
506+ TestShouldRestoreMetadata tests the shouldRestoreMetadata function of the AlluxioEngine.
507+ It creates a set of test datasets and initializes a fake client with these datasets.
508+ Then, it creates two AlluxioEngine instances with different configurations and checks
509+ if the shouldRestoreMetadata function returns the expected results for each instance.
510+ The test cases include:
511+ - An engine with a dataset that has a DataRestoreLocation specified, expecting shouldRestoreMetadata to return true.
512+ - An engine with a dataset that does not have a DataRestoreLocation specified, expecting shouldRestoreMetadata to return false.
513+ If the function does not return the expected result or an error occurs, the test will fail.
514+ */
505515func TestShouldRestoreMetadata (t * testing.T ) {
506516 datasetInputs := []datav1alpha1.Dataset {
507517 {
You can’t perform that action at this time.
0 commit comments