Closed luky116 closed 1 month ago
本次更改优化了多个测试文件中的数据库清理逻辑。所有文件中的 FlushDB
方法现已去掉错误检查,采用更简化的调用方式,以应对已知问题(问题 #401)。同时,部分测试中的数据库清理后的等待时间增加至 2 秒,以确保数据库状态的完全更新,提升测试的稳定性。此外,GitHub Actions 的测试命令也增加了详细输出的标志,增强了调试信息。
文件路径 | 更改摘要 |
---|---|
tests/hash_test.go, tests/key_test.go, tests/list_test.go, tests/set_test.go, tests/zset_test.go | 所有文件的 BeforeEach 函数中将 FlushDB 的错误检查注释掉,部分测试的等待时间增加至 2 秒。 |
.github/workflows/pikiwidb.yml | 测试命令中增加 --ginkgo.v 标志,以启用详细输出。 |
tests/print_log.sh | 新增脚本以便打印日志文件,提升日志查看的便利性。 |
Objective | Addressed | Explanation |
---|---|---|
解决执行 flushall 命令时的错误 (问题 #401) |
❌ | 本次修改未直接解决 flushall 错误,依然存在潜在问题。 |
🐇
在测试中我跳跃欢,
清理数据库无烦恼。
异常检查暂时藏,
兔子们乐享新方式!
等待时间长一秒,
测试稳定更桃红!
🐇
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
1、flushdb 的返回值直接打印日志,不 assert 2、执行完成 E2E 的测试,将 Pika 的日志进行打印
fix: https://github.com/OpenAtomFoundation/pikiwidb/issues/401
Summary by CodeRabbit
Bug Fixes
Improvements
新功能