[Core] Session class

Review Request #22 — Created Dec. 6, 2012 and submitted

Felipe
Lunr
master
lunr
Class that deals with session handling. Unit tests in progress, please comment if you see something wrong.
Unit Tests
  • 0
  • 0
  • 17
  • 0
  • 17
Description From Last Updated
olivier
  1. Looks fine and simple, I would say ship it!
  2. 
      
olivier
  1. Ship It!
    1. No no no no no no nooooooo!! no shipits without unittests!!
  2. 
      
pprkut
  1. 
      
  2. system/libraries/core/class.session.inc.php (Diff revision 1)
     
     
     
    I was trying to keep that list alphabetical...
  3. system/libraries/core/class.session.inc.php (Diff revision 1)
     
     
     
     
     
     
    not necessary
  4. system/libraries/core/class.session.inc.php (Diff revision 1)
     
     
     
     
     
    Code style
  5. not necessary
  6. not necessary
  7. 
      
Felipe
Felipe
Felipe
pprkut
  1. Mostly fine
  2. src/Lunr/Core/Session.php (Diff revision 3)
     
     
    this should return NULL
  3. src/Lunr/Core/Session.php (Diff revision 3)
     
     
     
    early exit
  4. src/Lunr/Core/Tests/SessionTest.php (Diff revision 3)
     
     
     
     
     
     
     
     
     
     
     
    I have the feeling phpcs will complain here.
    1. yep, it complained because I didn't have a white line between this constant and the first function :P
  5. 
      
Felipe
Felipe
pprkut
  1. 
      
  2. src/Lunr/Core/Session.php (Diff revision 5)
     
     
  3. src/Lunr/Core/Session.php (Diff revision 5)
     
     
     
     
     
     
     
     
     
     
     
     
    not in between __construct() and __destruct()
  4. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
     
     
     
     
     
     
     
     
     
     
     
    This is not sufficient, since you don't test the passed parameters. Please add tests for expected and unexpected parameters.
  5. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
    'set' is already public
  6. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
    ditto
  7. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
    ditto
  8. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
    ditto
  9. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
    I'd add an assertArrayHasKey or whatever it's called before
  10. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
    not necessary, just declare it @runInSeparateProcess
  11. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
     
    ok, so just to be sure, you really only need this if the method is protected or private
  12. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
    wrong name
    1. could I get an example that your Majesty likes? :P 
      
      http://devopsreactions.tumblr.com/post/37780353353/code-review-reviewee
    2. well, it returns NULL not FALSE :P
    3. I realized that just a few seconds after replying.... (facepalm)
      
  13. src/Lunr/Core/Tests/SessionBaseTest.php (Diff revision 5)
     
     
    wrong name
  14. 
      
Felipe
pprkut
  1. Ship It!
  2. 
      
Felipe
Review request changed

Status: Closed (submitted)

Change Summary:

Merged into master
Loading...