DiceDB / dice

DiceDB is hyper-optimized for building and scaling truly real-time applications on modern hardware. It is a drop-in replacement for Redis with support for SQL-based reactivity.
https://dicedb.io/
Other
3.32k stars 420 forks source link

Create helper methods to port TCL based Integration Tests from Redis 7.2.5 #138

Closed arpitbbhayani closed 3 days ago

AshwinKul28 commented 1 month ago

I would like to work on it of this is still valid, and would like to understand more on the requirement. @arpitbbhayani

AshwinKul28 commented 1 month ago

HI @JyotinderSingh Can you please assign this to me?

JyotinderSingh commented 1 month ago

HI @JyotinderSingh Can you please assign this to me?

Assigned

AshwinKul28 commented 3 weeks ago

One helper website: https://www.codeconvert.ai/tcl-to-golang-converter

AshwinKul28 commented 2 weeks ago

Work done till now:

Changes made in the executeCommand function

    // For running redis tests
    if cmd.Cmd == "SELECT" || cmd.Cmd == "FUNCTION" ||
        cmd.Cmd == "FLUSHALL" || cmd.Cmd == "CONFIG" ||
        cmd.Cmd == "RPUSH" || cmd.Cmd == "HSET" ||
        cmd.Cmd == "LRANGE" || cmd.Cmd == "ACL" ||
        cmd.Cmd == "FLUSHDB" || cmd.Cmd == "SCAN" ||
        cmd.Cmd == "SCARD" || cmd.Cmd == "ZCARD" {
        return RespOK
    }

The above commands are skipped because not implemented in the dice.

Command to run tests from Redis:

$ /runtest --host 127.0.0.1 --port 7379 --tags -needs:debug --tags -cluster:skip

It automatically skips those tests that have the tag -external:skip when running on an external server. We will see what to do about those tests.

[just a basic run. Now, I will dig deeper into it 🙂]

redis-tcl-integration-report.txt

Many tests failed, but many passed

AshwinKul28 commented 1 week ago

Still working on it :)

lucifercr07 commented 1 week ago

@AshwinKul28 would like to contribute along the same, please let me know if we can split tasks.

lucifercr07 commented 3 days ago

Initial integration test framework has been merged as part of this PR. Follow up unit tests would be taken care as part of below issues, hence closing this one. https://github.com/DiceDB/dice/issues/448 https://github.com/DiceDB/dice/issues/449