Review Request 112965: add asset/forum/:assetId

Giorgos Tsiapaliokas terietor at gmail.com
Fri Sep 27 11:05:38 UTC 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/112965/
-----------------------------------------------------------

Review request for Bodega.


Description
-------

Add a new route which returns the messages from the forum.
The json looks like this

{
  "authStatus": true,
  "device": "KDE-1",
  "store": "KDE-1",
  "points": 10000,
  "success": true,
  "topics": [
    {
      "title": "Foo bar linux12342425",
      "message": "<p>foo bar linux123423235235235</p>"
    },
    {
      "title": "Foo bar linux123424566",
      "message": "<p>foo bar linux1234578896666</p>"
    },
    {
      "title": "Foo bar linux1234245",
      "message": "<p>foo bar linux12342245</p>"
    },
    {
      "title": "Foo bar linux1234",
      "message": "<p>foo bar linux1234566</p>"
    },
    {
      "title": "Foo bar ioanna maria 1foo bar ioanna maria 1adsasd",
      "message": "<p>88971238912389()(<em>()DAS</em>()A*(DS()<em>ADS(</em>()ADS908foo bar ioanna maria 1foo bar ioanna maria 1foo bar ioanna maria 1foo bar ioanna maria 1</p>"
    }
  ]
}


Diffs
-----

  server/doc/bodega.json 4efa14e 
  server/lib/bodegadb.js 6d0c367 
  server/lib/db/forum.js PRE-CREATION 
  server/lib/utils.js e95b6ba 
  server/routes.js f0be1b4 
  server/test/forum.js PRE-CREATION 

Diff: http://git.reviewboard.kde.org/r/112965/diff/


Testing
-------

$ make test/forum
./node_modules/.bin/mocha test/forum.js --reporter spec
WARNING: Setting up server with no ssl!
Bodega server listening on localhost:3001 in devel mode


  Forum
    Authorization
      ? succeeds (75ms)
    List Messages
      ? should fail because the asset is invalid 
      ? should succeed (3313ms) <------------------------------------------------------ Probably something is wrong here. It takes 3 seconds and both bodega-server and the forum are in localhost.
                                                                                        I did this.timeout(15000) in order to pass the test

  3 passing (3 seconds)


Thanks,

Giorgos Tsiapaliokas

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/active/attachments/20130927/5ec4d0db/attachment.html>


More information about the Active mailing list