flushdb_test.go
flushdb_test.go - Overview
This file contains a test case for the FLUSHDB
command in the ironhawk
package. It verifies that FLUSHDB
correctly removes all keys from the database.
Detailed Documentation
TestFLUSHDB
Purpose: Tests the FLUSHDB
command to ensure it deletes all keys in the database.
Parameters:
t
(*testing.T): Testing framework instance.
Returns: None
The function establishes a local connection to the database, sets some keys, executes FLUSHDB
, and then verifies that the keys have been removed.
testCases
Purpose: Defines the test cases for the FLUSHDB
command.
Type: []TestCase
Each TestCase
includes a name, a list of commands to execute, and the expected results.
Code Examples
None