@@ -16,34 +16,34 @@ final class DriverTest extends TestCase
16
16
{
17
17
public function testDriverRegistered (): void
18
18
{
19
- self :: assertInstanceOf (ObsAdapter::class, Storage::disk ('obs ' )->getAdapter ());
19
+ $ this -> assertInstanceOf (ObsAdapter::class, Storage::disk ('obs ' )->getAdapter ());
20
20
}
21
21
22
22
public function testUrl (): void
23
23
{
24
- self :: assertStringStartsWith ('https://test-url ' , Storage::disk ('obs-url ' )->url ('test ' ));
24
+ $ this -> assertStringStartsWith ('https://test-url ' , Storage::disk ('obs-url ' )->url ('test ' ));
25
25
}
26
26
27
27
public function testTemporaryUrl (): void
28
28
{
29
- self :: assertStringStartsWith (
29
+ $ this -> assertStringStartsWith (
30
30
'https://test-temporary-url ' ,
31
31
Storage::disk ('obs-temporary-url ' )->temporaryUrl ('test ' , Carbon::now ()->addMinutes ())
32
32
);
33
33
}
34
34
35
35
public function testBucketEndpoint (): void
36
36
{
37
- self :: assertStringStartsWith ('https://your-endpoint ' , Storage::disk ('obs-bucket-endpoint ' )->url ('test ' ));
37
+ $ this -> assertStringStartsWith ('https://your-endpoint ' , Storage::disk ('obs-bucket-endpoint ' )->url ('test ' ));
38
38
}
39
39
40
40
public function testIsCname (): void
41
41
{
42
- self :: assertStringStartsWith (
42
+ $ this -> assertStringStartsWith (
43
43
'https://your-endpoint ' ,
44
44
Storage::disk ('obs-bucket-endpoint ' )->temporaryUrl ('test ' , Carbon::now ()->addMinutes ())
45
45
);
46
- self :: assertStringStartsWith (
46
+ $ this -> assertStringStartsWith (
47
47
'https://your-endpoint ' ,
48
48
Storage::disk ('obs-is-cname ' )->temporaryUrl ('test ' , Carbon::now ()->addMinutes ())
49
49
);
@@ -57,23 +57,23 @@ public function testReadOnly(): void
57
57
58
58
public function testPrefix (): void
59
59
{
60
- self :: assertSame (
60
+ $ this -> assertSame (
61
61
'https://your-bucket.your-endpoint/root/prefix/test ' ,
62
62
Storage::disk ('obs-prefix-url ' )->url ('test ' )
63
63
);
64
- self :: assertStringStartsWith (
64
+ $ this -> assertStringStartsWith (
65
65
'https://your-bucket.your-endpoint/root/prefix/test ' ,
66
66
Storage::disk ('obs-prefix-url ' )->temporaryUrl ('test ' , Carbon::now ()->addMinutes ())
67
67
);
68
68
}
69
69
70
70
public function testReadOnlyAndPrefix (): void
71
71
{
72
- self :: assertSame (
72
+ $ this -> assertSame (
73
73
'https://your-bucket.your-endpoint/root/prefix/test ' ,
74
74
Storage::disk ('obs-read-only-and-prefix-url ' )->url ('test ' )
75
75
);
76
- self :: assertStringStartsWith (
76
+ $ this -> assertStringStartsWith (
77
77
'https://your-bucket.your-endpoint/root/prefix/test ' ,
78
78
Storage::disk ('obs-read-only-and-prefix-url ' )->temporaryUrl ('test ' , Carbon::now ()->addMinutes ())
79
79
);
@@ -85,11 +85,11 @@ public function testTemporaryUploadUrl(): void
85
85
{
86
86
$ now = Carbon::now ()->addMinutes ();
87
87
$ data = Storage::disk ('obs-temporary-url ' )->temporaryUploadUrl ('test ' , $ now );
88
- self :: assertStringStartsWith (
88
+ $ this -> assertStringStartsWith (
89
89
sprintf ('https://test-temporary-url/test?AccessKeyId&Expires=%d&Signature= ' , $ now ->getTimestamp ()),
90
90
$ data ['url ' ]
91
91
);
92
- self :: assertSame ([
92
+ $ this -> assertSame ([
93
93
'Host ' => 'your-bucket.your-endpoint ' ,
94
94
], $ data ['headers ' ]);
95
95
}
0 commit comments