File tree Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Expand file tree Collapse file tree 4 files changed +17
-17
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public static function getLaravelLogFiles()
1818 $ files = [];
1919
2020 foreach (self ::getHandlers () as $ handler ) {
21- if ($ handler instanceof StreamHandler && !$ handler instanceof RotatingFileHandler) {
21+ if ($ handler instanceof StreamHandler && ! $ handler instanceof RotatingFileHandler) {
2222 $ files [] = $ handler ->getUrl ();
2323 }
2424 }
@@ -29,7 +29,7 @@ public static function getLaravelLogFiles()
2929 public static function closeHandlers ()
3030 {
3131 foreach (self ::getHandlers () as $ handler ) {
32- if ($ handler instanceof StreamHandler && !$ handler instanceof RotatingFileHandler) {
32+ if ($ handler instanceof StreamHandler && ! $ handler instanceof RotatingFileHandler) {
3333 if (method_exists ($ handler , 'close ' )) {
3434 $ handler ->close ();
3535 }
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ public function itCanRotateFileMax()
6161 {
6262 $ file = $ this ->tmpDir .'/file1 ' ;
6363
64- for ($ n = 0 ; $ n < 5 ; ++ $ n ) {
64+ for ($ n = 0 ; $ n < 5 ; $ n ++ ) {
6565 file_put_contents ($ file , 'test ' );
6666
6767 $ resultCode = Artisan::call ('rotate:files ' , [
@@ -76,7 +76,7 @@ public function itCanRotateFileMax()
7676
7777 $ this ->assertEquals (filesize ($ file ), 0 );
7878
79- for ($ n = 1 ; $ n < 4 ; ++ $ n ) {
79+ for ($ n = 1 ; $ n < 4 ; $ n ++ ) {
8080 $ this ->assertFileExists ($ file .'. ' .$ n .'.gz ' );
8181 }
8282
Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ public function testItCanRotateLogsWithMaxfiles()
5454
5555 $ this ->app ['config ' ]->set ('rotate.log_compress_files ' , true );
5656
57- for ($ n = 0 ; $ n < 10 ; ++ $ n ) {
57+ for ($ n = 0 ; $ n < 10 ; $ n ++ ) {
5858 $ this ->writeLog ();
5959
6060 $ this ->assertGreaterThan (0 , filesize (app ()->storagePath ().'/logs/laravel.log ' ));
Original file line number Diff line number Diff line change @@ -103,12 +103,12 @@ public function testItNotRotateLogsDaily()
103103 public function testItCanRotateLogsCustomStreamFile ()
104104 {
105105 $ this ->app ['config ' ]->set ('logging.channels.custom ' , [
106- 'driver ' => 'monolog ' ,
107- 'handler ' => StreamHandler::class,
108- 'with ' => [
109- 'stream ' => app ()->storagePath ().'/logs/custom.log ' ,
110- ],
111- ]);
106+ 'driver ' => 'monolog ' ,
107+ 'handler ' => StreamHandler::class,
108+ 'with ' => [
109+ 'stream ' => app ()->storagePath ().'/logs/custom.log ' ,
110+ ],
111+ ]);
112112
113113 $ this ->app ['config ' ]->set ('logging.default ' , 'custom ' );
114114
@@ -129,12 +129,12 @@ public function testItCanRotateLogsCustomStreamFile()
129129 public function testItNotRotateLogsCustomStreamStd ()
130130 {
131131 $ this ->app ['config ' ]->set ('logging.channels.custom ' , [
132- 'driver ' => 'monolog ' ,
133- 'handler ' => StreamHandler::class,
134- 'with ' => [
135- 'stream ' => 'php://stdout ' ,
136- ],
137- ]);
132+ 'driver ' => 'monolog ' ,
133+ 'handler ' => StreamHandler::class,
134+ 'with ' => [
135+ 'stream ' => 'php://stdout ' ,
136+ ],
137+ ]);
138138
139139 $ this ->app ['config ' ]->set ('logging.default ' , 'custom ' );
140140
You can’t perform that action at this time.
0 commit comments