Skip to content

Commit 3ad691a

Browse files
committed
fix github actions
1 parent 0e4f240 commit 3ad691a

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

tests/system/Files/FileTest.php

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,7 @@ public function testGetSizeReturnsBytes(): void
113113
$this->assertSame($size, $file->getSizeByUnit('b'));
114114
}
115115

116-
/**
117-
* @dataProvider provideGetSizeData
118-
*/
116+
#[\PHPUnit\Framework\Attributes\DataProvider('provideGetSizeData')]
119117
public function testGetSizeBinary(FileSizeUnit $unit): void
120118
{
121119
$divider = 1024 ** $unit->value;
@@ -131,9 +129,7 @@ public function testGetSizeBinaryBytes(): void
131129
$this->assertSame($size, $file->getSizeByUnitBinary(FileSizeUnit::B));
132130
}
133131

134-
/**
135-
* @dataProvider provideGetSizeData
136-
*/
132+
#[\PHPUnit\Framework\Attributes\DataProvider('provideGetSizeData')]
137133
public function testGetSizeMetric(FileSizeUnit $unit): void
138134
{
139135
$divider = 1000 ** $unit->value;
@@ -173,22 +169,22 @@ public function testGetDestination(): void
173169
}
174170

175171
/**
176-
* @return Array<string, Array<int>>
172+
* @return @return array<string, list<int>>
177173
*/
178-
public static function provideGetSizeData()
174+
public static function provideGetSizeData(): iterable
179175
{
180176
return [
181177
'returns KB binary' => [
182-
FileSizeUnit::KB
178+
FileSizeUnit::KB,
183179
],
184180
'returns MB binary' => [
185-
FileSizeUnit::KB
181+
FileSizeUnit::MB,
186182
],
187183
'returns GB binary' => [
188-
FileSizeUnit::KB
184+
FileSizeUnit::GB,
189185
],
190186
'returns TB binary' => [
191-
FileSizeUnit::KB
187+
FileSizeUnit::TB,
192188
],
193189
];
194190
}

0 commit comments

Comments
 (0)