Skip to content

Commit 9933a2a

Browse files
Copilotdevstress
andcommitted
Fix code formatting issues identified by SonarCloud
Co-authored-by: devstress <30769729+devstress@users.noreply.github.com>
1 parent 2c86541 commit 9933a2a

File tree

70 files changed

+1676
-1152
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+1676
-1152
lines changed

FlinkDotNet/Flink.JobBuilder.Tests/JobDefinitionValidatorComprehensiveBranchCoverageTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ private static JobDefinition CreateMinimalJob(ISourceDefinition? source = null)
213213
},
214214
Metadata = new JobMetadata
215215
{
216-
JobName = "Test Job"
216+
JobName = "Test Job"
217217
}
218218
};
219219
}

FlinkDotNet/Flink.JobBuilder.Tests/JobStatusBranchCoverageTests.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public void Duration_WhenBothStartAndEndTimeSet_CalculatesDifference()
1717
// Arrange
1818
var status = new JobStatus
1919
{
20-
State = "FINISHED",
20+
State = "FINISHED",
2121
StartTime = new DateTime(2025, 1, 1, 10, 0, 0, DateTimeKind.Utc),
2222
EndTime = new DateTime(2025, 1, 1, 11, 30, 0, DateTimeKind.Utc)
2323
};
@@ -36,7 +36,7 @@ public void Duration_WhenOnlyStartTimeSet_ReturnsNull()
3636
// Arrange
3737
var status = new JobStatus
3838
{
39-
State = "RUNNING",
39+
State = "RUNNING",
4040
StartTime = new DateTime(2025, 1, 1, 10, 0, 0, DateTimeKind.Utc),
4141
EndTime = null
4242
};
@@ -54,7 +54,7 @@ public void Duration_WhenOnlyEndTimeSet_ReturnsNull()
5454
// Arrange
5555
var status = new JobStatus
5656
{
57-
State = "FAILED",
57+
State = "FAILED",
5858
StartTime = null,
5959
EndTime = new DateTime(2025, 1, 1, 11, 30, 0, DateTimeKind.Utc)
6060
};
@@ -72,7 +72,7 @@ public void Duration_WhenBothTimesNull_ReturnsNull()
7272
// Arrange
7373
var status = new JobStatus
7474
{
75-
State = "CREATED",
75+
State = "CREATED",
7676
StartTime = null,
7777
EndTime = null
7878
};
@@ -90,7 +90,7 @@ public void JobStatus_WithErrorMessage_StoresValue()
9090
// Arrange & Act
9191
var status = new JobStatus
9292
{
93-
State = "FAILED",
93+
State = "FAILED",
9494
ErrorMessage = "Connection timeout"
9595
};
9696

@@ -112,7 +112,7 @@ public void JobStatus_WithMetrics_StoresValue()
112112
// Act
113113
var status = new JobStatus
114114
{
115-
Metrics = metrics
115+
Metrics = metrics
116116
};
117117

118118
// Assert

FlinkDotNet/Flink.JobBuilder.Tests/Tests/FlinkJobGatewayServiceCompleteCoverageTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ private JobDefinition CreateValidJobDefinition()
510510
{
511511
Metadata = new JobMetadata
512512
{
513-
JobName = "Test Job",
513+
JobName = "Test Job",
514514
Version = "1.0.0"
515515
},
516516
Source = new KafkaSourceDefinition

FlinkDotNet/Flink.JobBuilder.Tests/Tests/FlinkJobGatewayServiceTests.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ public async Task SubmitJobAsync_WithValidJob_ReturnsSuccess()
182182
// Arrange
183183
var responseJson = this.SerializeJobSubmissionResult(new JobSubmissionResult
184184
{
185-
FlinkJobId = "flink-123",
185+
FlinkJobId = "flink-123",
186186
Success = true
187187
});
188188

@@ -566,7 +566,7 @@ public async Task SubmitJobAsync_WithServerError_RetriesAndSucceeds()
566566
}
567567
var resultJson = this.SerializeJobSubmissionResult(new JobSubmissionResult
568568
{
569-
FlinkJobId = "flink-retry",
569+
FlinkJobId = "flink-retry",
570570
Success = true
571571
});
572572
return new HttpResponseMessage(HttpStatusCode.OK)
@@ -632,7 +632,7 @@ public async Task SubmitJobAsync_With429TooManyRequests_Retries()
632632
}
633633
var resultJson = this.SerializeJobSubmissionResult(new JobSubmissionResult
634634
{
635-
FlinkJobId = "flink-rate",
635+
FlinkJobId = "flink-rate",
636636
Success = true
637637
});
638638
return new HttpResponseMessage(HttpStatusCode.OK)
@@ -677,7 +677,7 @@ public async Task SubmitJobAsync_WithFlinkClusterNotReady_Retries()
677677
}
678678
var resultJson = this.SerializeJobSubmissionResult(new JobSubmissionResult
679679
{
680-
FlinkJobId = "flink-ready",
680+
FlinkJobId = "flink-ready",
681681
Success = true
682682
});
683683
return new HttpResponseMessage(HttpStatusCode.OK)
@@ -791,7 +791,7 @@ public async Task SubmitJobAsync_WithExceptionDuringRetry_LogsAndRetries()
791791
}
792792
var resultJson = this.SerializeJobSubmissionResult(new JobSubmissionResult
793793
{
794-
FlinkJobId = "flink-exception",
794+
FlinkJobId = "flink-exception",
795795
Success = true
796796
});
797797
return new HttpResponseMessage(HttpStatusCode.OK)

FlinkDotNet/Flink.JobBuilder.Tests/Tests/JobDefinitionModelTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ public void JobMetadata_AllProperties_CanBeSet()
104104

105105
var metadata = new JobMetadata
106106
{
107-
JobName = "Test Job",
107+
JobName = "Test Job",
108108
CreatedAt = createdAt,
109109
Version = "1.0.0",
110110
Parallelism = 8,

FlinkDotNet/Flink.JobBuilder.Tests/Tests/JobDefinitionValidatorBatch7Tests.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ public void Validate_WithEmptyVersion_ReturnsError()
374374
{
375375
Metadata = new JobMetadata
376376
{
377-
Version = "" // Invalid
377+
Version = "" // Invalid
378378
},
379379
Source = new KafkaSourceDefinition
380380
{
@@ -400,7 +400,7 @@ public void Validate_WithZeroParallelism_ReturnsError()
400400
{
401401
Metadata = new JobMetadata
402402
{
403-
Version = "1.0",
403+
Version = "1.0",
404404
Parallelism = 0 // Invalid
405405
},
406406
Source = new KafkaSourceDefinition
@@ -427,7 +427,7 @@ public void Validate_WithNegativeParallelism_ReturnsError()
427427
{
428428
Metadata = new JobMetadata
429429
{
430-
Version = "1.0",
430+
Version = "1.0",
431431
Parallelism = -5 // Invalid
432432
},
433433
Source = new KafkaSourceDefinition
@@ -525,7 +525,7 @@ public void Validate_WithValidNonSqlJob_IsValid()
525525
{
526526
Metadata = new JobMetadata
527527
{
528-
Version = "1.0",
528+
Version = "1.0",
529529
Parallelism = 4
530530
},
531531
Source = new KafkaSourceDefinition

FlinkDotNet/Flink.JobBuilder.Tests/Tests/JobResultsModelTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ public void JobExecutionResult_SetAllProperties_ReturnsValues()
151151

152152
var result = new JobExecutionResult
153153
{
154-
FlinkJobId = "flink-456",
154+
FlinkJobId = "flink-456",
155155
State = "FINISHED",
156156
Success = true,
157157
Error = null,
@@ -241,7 +241,7 @@ public void JobStatus_SetAllProperties_ReturnsValues()
241241

242242
var status = new JobStatus
243243
{
244-
FlinkJobId = "flink-456",
244+
FlinkJobId = "flink-456",
245245
State = "RUNNING",
246246
StartTime = startTime,
247247
EndTime = endTime,

FlinkDotNet/Flink.JobBuilder.Tests/Tests/ModelIntegrationTests.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public void JobDefinition_CompleteStreamingJob_AllComponentsPresent()
3737
},
3838
Metadata = new JobMetadata
3939
{
40-
JobName = "Streaming Aggregation Job",
40+
JobName = "Streaming Aggregation Job",
4141
Parallelism = 4,
4242
Version = "1.0.0"
4343
}
@@ -67,7 +67,7 @@ public void JobDefinition_SqlJob_NoSinkRequired()
6767
Sink = null,
6868
Metadata = new JobMetadata
6969
{
70-
JobName = "Pure SQL Job"
70+
JobName = "Pure SQL Job"
7171
}
7272
};
7373

@@ -392,7 +392,7 @@ public void JobMetadata_WithCustomProperties_ComplexScenario()
392392
{
393393
var metadata = new JobMetadata
394394
{
395-
JobName = "Production Data Pipeline",
395+
JobName = "Production Data Pipeline",
396396
CreatedAt = DateTime.UtcNow,
397397
Version = "2.1.0",
398398
Parallelism = 16,
@@ -464,7 +464,7 @@ public void JobStatus_CompleteLifecycle_DurationCalculated()
464464

465465
var status = new JobStatus
466466
{
467-
FlinkJobId = "flink-456",
467+
FlinkJobId = "flink-456",
468468
State = "FINISHED",
469469
StartTime = startTime,
470470
EndTime = endTime,

FlinkDotNet/Flink.JobBuilder.Tests/Tests/PerformanceConfigModelTests.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ public void JobMetadata_WithStateBackendConfig_StoresStateBackendSettings()
337337

338338
var metadata = new JobMetadata
339339
{
340-
StateBackendConfig = stateBackendConfig
340+
StateBackendConfig = stateBackendConfig
341341
};
342342

343343
Assert.That(metadata.StateBackendConfig, Is.Not.Null);
@@ -378,7 +378,7 @@ public void JobDefinition_WithBatchingAndStateBackend_StoresBothConfigs()
378378
},
379379
Metadata = new JobMetadata
380380
{
381-
StateBackendConfig = new StateBackendConfig
381+
StateBackendConfig = new StateBackendConfig
382382
{
383383
Type = "rocksdb",
384384
CheckpointDir = "s3://bucket/checkpoints",
@@ -632,7 +632,7 @@ public void JobMetadata_WithExecutionPlanConfig_StoresExecutionPlanSettings()
632632

633633
var metadata = new JobMetadata
634634
{
635-
ExecutionPlanConfig = planConfig
635+
ExecutionPlanConfig = planConfig
636636
};
637637

638638
Assert.That(metadata.ExecutionPlanConfig, Is.Not.Null);
@@ -651,7 +651,7 @@ public void JobMetadata_WithOptimizerConfig_StoresOptimizerSettings()
651651

652652
var metadata = new JobMetadata
653653
{
654-
OptimizerConfig = optimizerConfig
654+
OptimizerConfig = optimizerConfig
655655
};
656656

657657
Assert.That(metadata.OptimizerConfig, Is.Not.Null);
@@ -664,7 +664,7 @@ public void JobMetadata_WithAllPerformanceConfigs_StoresAllSettings()
664664
{
665665
var metadata = new JobMetadata
666666
{
667-
StateBackendConfig = new StateBackendConfig
667+
StateBackendConfig = new StateBackendConfig
668668
{
669669
Type = "rocksdb",
670670
CheckpointDir = "s3://bucket/checkpoints"
@@ -715,7 +715,7 @@ public void JobDefinition_WithAll4PerformanceFeatures_StoresAllConfigs()
715715
},
716716
Metadata = new JobMetadata
717717
{
718-
StateBackendConfig = new StateBackendConfig
718+
StateBackendConfig = new StateBackendConfig
719719
{
720720
Type = "rocksdb",
721721
CheckpointDir = "s3://production/checkpoints",

FlinkDotNet/Flink.JobBuilder.Tests/Tests/SourceSinkDefinitionsTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@ public void JobMetadata_JobName_SupportsNull()
551551
{
552552
var metadata = new JobMetadata
553553
{
554-
JobName = null
554+
JobName = null
555555
};
556556

557557
Assert.That(metadata.JobName, Is.Null);
@@ -562,7 +562,7 @@ public void JobMetadata_JobName_CanBeSet()
562562
{
563563
var metadata = new JobMetadata
564564
{
565-
JobName = "My Flink Job"
565+
JobName = "My Flink Job"
566566
};
567567

568568
Assert.That(metadata.JobName, Is.EqualTo("My Flink Job"));

0 commit comments

Comments
 (0)