test(09-02): update auto-assign range assertions to [2500, 4000] Hz
- Update TestAutoFreqAssignment bounds from [1200, 2350] to [2500, 4000] - Update TestAutoFreqAssignment comment to reflect new range - Update TestAutoFreqSkipsBuiltins HTTPS expected value from 175.0 to 150.0 (coordinated with Plan 01 frequency rebalancing)
This commit is contained in:
@@ -342,7 +342,7 @@ class = "MyService"
|
||||
}
|
||||
|
||||
// TestAutoFreqAssignment: TOML with [[rules]] (class="GameServer", protocol="tcp") and
|
||||
// NO [sounds.GameServer] -> FreqCfgs contains "GameServer" entry with BaseHz in [1200, 2350]
|
||||
// NO [sounds.GameServer] -> FreqCfgs contains "GameServer" entry with BaseHz in [2500, 4000]
|
||||
// and WaveformType == WaveformSine.
|
||||
func TestAutoFreqAssignment(t *testing.T) {
|
||||
toml := `
|
||||
@@ -360,8 +360,8 @@ class = "GameServer"
|
||||
if !ok {
|
||||
t.Fatal("FreqCfgs should contain 'GameServer' entry from auto-freq assignment")
|
||||
}
|
||||
if cfg.BaseHz < 1200.0 || cfg.BaseHz > 2350.0 {
|
||||
t.Errorf("GameServer BaseHz: got %v, want in [1200, 2350]", cfg.BaseHz)
|
||||
if cfg.BaseHz < 2500.0 || cfg.BaseHz > 4000.0 {
|
||||
t.Errorf("GameServer BaseHz: got %v, want in [2500, 4000]", cfg.BaseHz)
|
||||
}
|
||||
if cfg.WaveformType != synth.WaveformSine {
|
||||
t.Errorf("GameServer WaveformType: got %v, want WaveformSine", cfg.WaveformType)
|
||||
@@ -559,7 +559,7 @@ class = "GameServer"
|
||||
}
|
||||
|
||||
// TestAutoFreqSkipsBuiltins: TOML with [[rules]] (class="HTTPS", protocol="tcp", port=443)
|
||||
// -> FreqCfgs["HTTPS"].BaseHz == 175.0 (the default), NOT an auto-assigned value.
|
||||
// -> FreqCfgs["HTTPS"].BaseHz == 150.0 (the default), NOT an auto-assigned value.
|
||||
func TestAutoFreqSkipsBuiltins(t *testing.T) {
|
||||
toml := `
|
||||
[[rules]]
|
||||
@@ -573,8 +573,8 @@ class = "HTTPS"
|
||||
if err != nil {
|
||||
t.Fatalf("Load: %v", err)
|
||||
}
|
||||
if result.FreqCfgs[classify.ClassHTTPS].BaseHz != 175.0 {
|
||||
t.Errorf("HTTPS BaseHz: got %v, want 175.0 (default, not auto-assigned)", result.FreqCfgs[classify.ClassHTTPS].BaseHz)
|
||||
if result.FreqCfgs[classify.ClassHTTPS].BaseHz != 150.0 {
|
||||
t.Errorf("HTTPS BaseHz: got %v, want 150.0 (default, not auto-assigned)", result.FreqCfgs[classify.ClassHTTPS].BaseHz)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user