Page MenuHomeDevCentral

Add notifications:payload command
ClosedPublic

Authored by dereckson on Aug 19 2016, 10:48.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Oct 31, 12:01
Unknown Object (File)
Sun, Oct 27, 08:33
Unknown Object (File)
Wed, Oct 23, 16:43
Unknown Object (File)
Tue, Oct 22, 09:14
Unknown Object (File)
Mon, Oct 21, 06:07
Unknown Object (File)
Sun, Oct 20, 07:36
Unknown Object (File)
Wed, Oct 16, 02:00
Unknown Object (File)
Wed, Oct 16, 01:13
Subscribers

Details

Summary

A CLI command to get a notification payload from a service payload.

The goal is to ease debug of consumers applications: you can get a
sample notification without the assistance of the message broker
for a specified problematic payload.

Fixes T983.

Test Plan

Used for D347.

Diff Detail

Repository
rNOTIF Notifications center
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dereckson retitled this revision from to Add notifications:payload command.
dereckson updated this object.
dereckson edited the test plan for this revision. (Show Details)
dereckson added a reviewer: dereckson.
dereckson added inline comments.
app/Console/Commands/NotificationsPayload.php
11

Test me.

12

Not on an individual line.

116

ensureCorrectArgumentsCount() ?

122

Document me.

129

Document me.

134

Document me.

There is an issue in logic code too.

  [ErrorException]                           
  Undefined property: stdClass::$repository  
                                             

Exception trace:
 () at /home/ubuntu/workspace/notifications/app/Notifications/DockerHubNotification.php:47
 Illuminate\Foundation\Bootstrap\HandleExceptions->handleError() at /home/ubuntu/workspace/notifications/app/Notifications/DockerHubNotification.php:47
 Nasqueron\Notifications\Notifications\DockerHubNotification->getText() at /home/ubuntu/workspace/notifications/app/Notifications/DockerHubNotification.php:37
 Nasqueron\Notifications\Notifications\DockerHubNotification->__construct() at /home/ubuntu/workspace/notifications/app/Console/Commands/NotificationsPayload.php:124
dereckson marked 4 inline comments as done.
dereckson edited edge metadata.

More tests.

There is an issue in logic code too.

[ErrorException]                           
Undefined property: stdClass::$repository

Payload was already a notification, not a DockerHub payload.

tests/Console/Commands/NotificationsPayloadTest.php
76

Add \EOL

dereckson edited edge metadata.
dereckson marked 3 inline comments as done.
This revision is now accepted and ready to land.Aug 19 2016, 12:50

Better code documentation

This revision was automatically updated to reflect the committed changes.