Page MenuHomeDevCentral

Add /status entry point
ClosedPublic

Authored by dereckson on Feb 15 2018, 10:48.
Tags
None
Referenced Files
F50879613: D1293.id.diff
Mon, Sep 21, 12:39
F50789750: D1293.id3324.diff
Sun, Sep 20, 22:29
F50783402: D1293.id3324.diff
Sun, Sep 20, 21:32
F50772310: D1293.id3325.diff
Sun, Sep 20, 19:45
F50742895: D1293.id3321.diff
Sun, Sep 20, 15:18
Unknown Object (File)
Sun, Sep 20, 07:29
Unknown Object (File)
Sat, Sep 19, 12:14
Unknown Object (File)
Fri, Sep 18, 23:01
Subscribers
None

Details

Summary

Allow to test if the service is running.

Send a GET /status request and check the service replies with a 200.

Test Plan

Tested through Postman.

Testing code
pm.test("Status code is 200", function () {
    pm.response.to.have.status(200);
});

pm.test("Body matches string", function () {
    pm.expect(pm.response.text()).to.include("ALIVE");
});

An unit test for the Service isn't possible right now, as the service
is a god object handling reading the web request and providing output.

To use PSR messages interfaces should be considered a good idea to
separate concerns.

Diff Detail

Lint
No Lint Coverage
Unit
No Test Coverage
Branch
alive
Build Status
Buildable 2048
Build 2296: arc lint + arc unit

Event Timeline

dereckson created this revision.
This revision is now accepted and ready to land.Feb 15 2018, 10:49
This revision was automatically updated to reflect the committed changes.