diff --git a/pkg/ddc/alluxio/transform_test.go b/pkg/ddc/alluxio/transform_test.go index cea65454e5b..65096a25d7a 100755 --- a/pkg/ddc/alluxio/transform_test.go +++ b/pkg/ddc/alluxio/transform_test.go @@ -862,6 +862,19 @@ func TestAlluxioEngine_allocatePorts(t *testing.T) { } } +// TestTransformMasterProperties tests the transformMasters function of AlluxioEngine. +// It verifies whether the master properties are correctly transformed based on the given runtime configuration. +// The test cases ensure that the properties from the master template take precedence over the global properties. +// +// Test Cases: +// 1. "master properties is not null": +// - Ensures that when master-specific properties exist, they override the global properties. +// +// 2. "properties is not null for master": +// - Ensures that both master-specific and additional global properties are correctly handled. +// +// The function iterates over multiple test cases and checks if the transformed properties +// match the expected values. If the transformation does not produce the expected result, the test fails. func TestTransformMasterProperties(t *testing.T) { engine := &AlluxioEngine{Log: fake.NullLogger()}