mirror of
https://github.com/EchoVault/SugarDB.git
synced 2025-10-10 02:10:17 +08:00
Implemented tests for AddCommand, ExecuteCommand and RemoveCommand methods
This commit is contained in:
@@ -421,7 +421,7 @@ func handleLPush(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
if err = params.SetValue(params.Context, key, append(newElems, l...)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return []byte(constants.OkResponse), nil
|
||||
return []byte(fmt.Sprintf(":%d\r\n", len(l)+len(newElems))), nil
|
||||
}
|
||||
|
||||
func handleRPush(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
@@ -469,7 +469,7 @@ func handleRPush(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
if err = params.SetValue(params.Context, key, append(l, newElems...)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return []byte(constants.OkResponse), nil
|
||||
return []byte(fmt.Sprintf(":%d\r\n", len(l)+len(newElems))), nil
|
||||
}
|
||||
|
||||
func handlePop(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
|
Reference in New Issue
Block a user