Completed
Push — master ( c9b09a...2a1f07 )
by Jivesh
15:35 queued 11:45
created
src/SlackServiceProvider.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
     {
14 14
         // Publish Config
15 15
         $this->publishes([
16
-            __DIR__ . '/../config/slack.php' => config_path('slack.php'),
16
+            __DIR__.'/../config/slack.php' => config_path('slack.php'),
17 17
         ]);
18 18
     }
19 19
 
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
     public function register()
24 24
     {
25 25
         // Register Facade
26
-        $this->app->bind('gahlawat.slack', function ($app) {
26
+        $this->app->bind('gahlawat.slack', function($app) {
27 27
             return new Slack;
28 28
         });
29 29
     }
Please login to merge, or discard this patch.
tests/Unit/ObjectTest.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -7,10 +7,10 @@
 block discarded – undo
7 7
 
8 8
 class ObjectTest extends TestCase
9 9
 {
10
-	public function testObjectCreation()
11
-	{
12
-		$slack = new Slack;
10
+    public function testObjectCreation()
11
+    {
12
+        $slack = new Slack;
13 13
 
14
-		$this->assertInstanceOf(Slack::class, $slack);
15
-	}
14
+        $this->assertInstanceOf(Slack::class, $slack);
15
+    }
16 16
 }
Please login to merge, or discard this patch.
src/Slack.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
 {
10 10
     public function send($message, $username = null, $emoji = null, $channel = null)
11 11
     {
12
-        if (! config('slack.incoming-webhook')) {
12
+        if (!config('slack.incoming-webhook')) {
13 13
             return;
14 14
         }
15 15
 
@@ -17,10 +17,10 @@  discard block
 block discarded – undo
17 17
         $channel  = trim($channel);
18 18
         $username = trim($username);
19 19
 
20
-        $payload['text']       = $message;
21
-        $payload['username']   = empty($username) ? config('slack.default_username') : $username;
22
-        $payload['icon_emoji'] = empty($emoji) ? config('slack.default_emoji') : $emoji;
23
-        $payload['channel']    = $channel;
20
+        $payload[ 'text' ]       = $message;
21
+        $payload[ 'username' ]   = empty($username) ? config('slack.default_username') : $username;
22
+        $payload[ 'icon_emoji' ] = empty($emoji) ? config('slack.default_emoji') : $emoji;
23
+        $payload[ 'channel' ]    = $channel;
24 24
 
25 25
         $headers = [
26 26
             'Content-Type' => 'application/json',
Please login to merge, or discard this patch.
tests/Feature/SendTest.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
      */
13 13
     public function testFailedSlackRequestWithEmptyMessage()
14 14
     {
15
-    	Slack::send();
15
+        Slack::send();
16 16
     }
17 17
 
18 18
     public function testFailedSlackRequestWithWrongEndpoint()
@@ -25,10 +25,10 @@  discard block
 block discarded – undo
25 25
 
26 26
     public function testSuccessfulSlackRequest()
27 27
     {
28
-    	config(['slack.incoming-webhook' => env('SAMPLE_WEBHOOK')]);
28
+        config(['slack.incoming-webhook' => env('SAMPLE_WEBHOOK')]);
29 29
 
30
-    	$response = Slack::send('hi');
30
+        $response = Slack::send('hi');
31 31
 
32
-    	$this->assertEquals(200, $response->getStatusCode());
32
+        $this->assertEquals(200, $response->getStatusCode());
33 33
     }
34 34
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
 
26 26
     public function testSuccessfulSlackRequest()
27 27
     {
28
-    	config(['slack.incoming-webhook' => env('SAMPLE_WEBHOOK')]);
28
+    	config([ 'slack.incoming-webhook' => env('SAMPLE_WEBHOOK') ]);
29 29
 
30 30
     	$response = Slack::send('hi');
31 31
 
Please login to merge, or discard this patch.
tests/TestCase.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
 {
10 10
     protected function getPackageProviders($app)
11 11
     {
12
-        return [SlackServiceProvider::class];
12
+        return [ SlackServiceProvider::class ];
13 13
     }
14 14
 
15 15
     protected function getPackageAliases($app)
@@ -21,6 +21,6 @@  discard block
 block discarded – undo
21 21
 
22 22
     protected function getEnvironmentSetUp($app)
23 23
     {
24
-        $app['config']['slack'] = require __DIR__ . '/../config/slack.php';
24
+        $app[ 'config' ][ 'slack' ] = require __DIR__.'/../config/slack.php';
25 25
     }
26 26
 }
Please login to merge, or discard this patch.