1. 22 Jan, 2015 8 commits
  2. 09 Jan, 2015 1 commit
  3. 11 Dec, 2014 1 commit
    • Matt Stancliff's avatar
      Fix zero-ordering SORT when called against lists · 77bbc0df
      Matt Stancliff authored
      People mostly use SORT against lists, but our prior
      behavior was pretending lists were an unordered bag
      requiring a forced-sort when no sort was requested.
      
      We can just use the native list ordering to ensure
      consistency across replicaion and scripting calls.
      
      Closes #2079
      Closes #545 (again)
      77bbc0df
  4. 03 Dec, 2014 1 commit
  5. 28 Nov, 2014 3 commits
  6. 24 Nov, 2014 1 commit
  7. 14 Nov, 2014 4 commits
    • antirez's avatar
      9466f3b3
    • Matt Stancliff's avatar
      Lua: add cmsgpack scripting tests · 8934c480
      Matt Stancliff authored
      Basically: test to make sure we can load cmsgpack
      and do some sanity checks to make sure pack/unpack works
      properly.  We also have a bonus test for circular encoding
      and decoding because I was curious how it worked.
      8934c480
    • Matt Stancliff's avatar
      Lua: add cjson scripting test · 330ebea4
      Matt Stancliff authored
      Two simple decode tests added mainly to check that
      the 'cjson' global gets registered and is usable.
      330ebea4
    • Matt Stancliff's avatar
      Lua: Add bitop · d071e5fe
      Matt Stancliff authored
      A few people have written custom C commands because bit
      manipulation isn't exposed through Lua.  Let's give
      them Mike Pall's bitop.
      
      This adds bitop 1.0.2 (2012-05-08) from http://bitop.luajit.org/
      
      bitop is imported as "bit" into the global namespace.
      
      New Lua commands: bit.tobit, bit.tohex, bit.bnot, bit.band, bit.bor, bit.bxor,
      bit.lshift, bit.rshift, bit.arshift, bit.rol, bit.ror, bit.bswap
      
      Verification of working (the asserts would abort on error, so (nil) is correct):
      127.0.0.1:6379> eval "assert(bit.tobit(1) == 1); assert(bit.band(1) == 1); assert(bit.bxor(1,2) == 3); assert(bit.bor(1,2,4,8,16,32,64,128) == 255)" 0
      (nil)
      127.0.0.1:6379> eval 'assert(0x7fffffff == 2147483647, "broken hex literals"); assert(0xffffffff == -1 or 0xffffffff == 2^32-1, "broken hex literals"); assert(tostring(-1) == "-1", "broken tostring()"); assert(tostring(0xffffffff) == "-1" or tostring(0xffffffff) == "4294967295", "broken tostring()")' 0
      (nil)
      
      Tests also integrated into the scripting tests and can be run with:
      ./runtest --single unit/scripting
      
      Tests are excerpted from `bittest.lua` included in the bitop distribution.
      d071e5fe
  8. 29 Oct, 2014 1 commit
  9. 08 Oct, 2014 2 commits
  10. 06 Oct, 2014 5 commits
  11. 17 Sep, 2014 3 commits
  12. 08 Sep, 2014 4 commits
  13. 01 Sep, 2014 1 commit
  14. 26 Aug, 2014 5 commits
    • Mariano Pérez Rodríguez's avatar
      Stop tests from leaving a black background · 4f29e859
      Mariano Pérez Rodríguez authored
      Uses ANSI "default background" color code after closing tests
      so any non-black terminals don't remain polluted.
      
      Fixes #1649
      Closes #1912
      4f29e859
    • Matt Stancliff's avatar
      Reject MOVE to non-integer DBs · 17438f7c
      Matt Stancliff authored
      Previously, "MOVE key somestring" would move the key to
      DB 0 which is just unexpected and wrong.
      String as DB == error.
      
      Test added too.
      
      Modified by @antirez in order to use the getLongLongFromObject() API
      instead of strtol().
      
      Fixes #1428
      17438f7c
    • Matt Stancliff's avatar
      pubsub: Return integers for NUMSUB, not strings · 961e5e20
      Matt Stancliff authored
      Also adds test for numsub — due to tcl being tcl,
      it doesn't capture the "numberness" of the fix,
      but now we at least have one test case for numsub.
      
      Closes #1561
      961e5e20
    • Matt Stancliff's avatar
      Fix key extraction for SORT · 14cedd42
      Matt Stancliff authored
      We only want to use the last STORE key, but we have to record
      we actually found a STORE key so we can increment the final return
      key count.
      
      Test added to prevent further regression.
      
      Closes #1883, #1645, #1647
      14cedd42
    • Jan-Erik Rediger's avatar
      Handle large getrange requests · b7a4cfb4
      Jan-Erik Rediger authored
      Previously the end was casted to a smaller type
      which resulted in a wrong check and failed
      with values larger than handled by unsigned.
      
      Closes #1847, #1844
      b7a4cfb4