@@ -44,11 +44,7 @@ class TestAnalyzeStreamerHeaders:
4444
4545 def test_non_overlapping_channels_returns_type_b (self ) -> None :
4646 """Non-overlapping cable channel ranges should produce Configuration B."""
47- records : list [tuple [int , int ]] = []
48- for cable in (1 , 2 , 3 ):
49- for chan in range (1 , 6 ):
50- records .append ((cable , (cable - 1 ) * 5 + chan ))
51-
47+ records = [(cable , (cable - 1 ) * 5 + chan ) for cable in (1 , 2 , 3 ) for chan in range (1 , 6 )]
5248 headers = _streamer_headers (records )
5349
5450 unique_cables , mins , maxs , geom = analyze_streamer_headers (headers )
@@ -60,11 +56,7 @@ def test_non_overlapping_channels_returns_type_b(self) -> None:
6056
6157 def test_overlapping_channels_returns_type_a (self ) -> None :
6258 """Overlapping channel ranges between cables should produce Configuration A."""
63- records : list [tuple [int , int ]] = []
64- for cable in (1 , 2 ):
65- for chan in range (1 , 6 ):
66- records .append ((cable , chan ))
67-
59+ records = [(cable , chan ) for cable in (1 , 2 ) for chan in range (1 , 6 )]
6860 headers = _streamer_headers (records )
6961 unique_cables , _ , _ , geom = analyze_streamer_headers (headers )
7062
@@ -102,11 +94,8 @@ def test_dense_shots_per_gun_returns_type_a(self) -> None:
10294 def test_interleaved_shots_returns_type_b (self ) -> None :
10395 """Interleaved shot numbering (unique per line, sparse per gun) -> Configuration B."""
10496 # Gun 1: odd shots, gun 2: even shots, all unique within the same line.
105- records = []
106- for shot in (1 , 3 , 5 ):
107- records .append ((200 , shot , 1 ))
108- for shot in (2 , 4 , 6 ):
109- records .append ((200 , shot , 2 ))
97+ records = [(200 , shot , 1 ) for shot in (1 , 3 , 5 )]
98+ records .extend ((200 , shot , 2 ) for shot in (2 , 4 , 6 ))
11099 headers = _gun_headers (records )
111100
112101 unique_lines , per_line , geom = analyze_lines_for_guns (headers , line_field = "sail_line" )
0 commit comments