File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -198,6 +198,27 @@ func TestSetupMasterInternal(t *testing.T) {
198198 wrappedUnhookCheckRelease ()
199199}
200200
201+ // TestGenerateJuiceFSValueFile tests the generateJuicefsValueFile method of the JuiceFSEngine.
202+ // This test verifies that the function correctly generates a JuiceFS configuration value file
203+ // from the provided JuiceFSRuntime specification. It covers the complete workflow including:
204+ // - Mock Kubernetes Secret creation with metadata URL
205+ // - JuiceFSRuntime specification with tiered storage configuration
206+ // - Dataset definition with mount points and encryption options
207+ // - Building runtime information
208+ // - JuiceFS engine initialization
209+ // - Value file generation execution
210+ //
211+ // The test ensures the function handles all required objects and configurations properly
212+ // and returns without errors.
213+ //
214+ // Key components tested:
215+ // - Secret handling for sensitive configuration data
216+ // - Tiered storage configuration parsing
217+ // - Mount point and encryption options processing
218+ // - JuiceFS engine runtime initialization
219+ //
220+ // Expected behavior: The function should successfully generate the JuiceFS value file
221+ // without returning any errors.
201222func TestGenerateJuiceFSValueFile (t * testing.T ) {
202223 juicefsSecret := & v1.Secret {
203224 ObjectMeta : metav1.ObjectMeta {
You can’t perform that action at this time.
0 commit comments