Skip to content

test(redis): isolated tests for the type-specific editors - #1098

Merged
ZhuchkaTriplesix merged 5 commits into
devfrom
issue/1040-nosql-tests
Oct 8, 2026
Merged

ZhuchkaTriplesix merged 5 commits into
devfrom
issue/1040-nosql-tests

Conversation

@ZhuchkaTriplesix

Copy link
Copy Markdown
Member

Summary

Adds test/features/redis/redis_type_editors_test.dart: isolated widget tests for the editors extracted in #1034 (RedisStringEditor, RedisHashEditor, RedisListEditor, RedisSetEditor, RedisZsetEditor), driven by plain callbacks without a connection.

  • String: value and Save, typing updates the parent-owned controller, read-only hides Save and locks the field, a binary value is shown as hex / base64 without Save.
  • Hash: fields and values, HSET trims the field name but keeps the value and clears the inputs, an empty field name is ignored, delete reports the field, read-only hides the add bar and delete icons, empty state and footer.
  • List: items with indexes, RPUSH (sent as typed, empty ignored), editing sends LSET with the value the item had (concurrency guard input), cancel / unchanged text sends nothing, delete reports index and item, binary items get a badge and no edit icon, read-only, empty state.
  • Set: SADD trims and ignores blanks, delete, read-only, empty state.
  • Sorted set: scores (whole numbers without decimals), ZADD parses the score and trims the member, an empty member or a non-numeric score is ignored, delete, read-only.

Coverage of the rest of #1040

Most of the listed suites already exist and are not duplicated here: Mongo view modes (mongo_documents_view_modes_test), aggregation (mongo_aggregation_stage_test, mongo_aggregation_workspace_test), indexes (mongo_indexes_view_test, mongo_index_info_test), MQL console (mongo_query_workspace_test, mql_parser_test), Redis key tree (redis_key_tree_engine_test) and CLI (redis_cli_workspace_test).

Still open: the Mongo collection tree suite (#1023). The tree widgets are private parts of ConnectionsPanel and need a Mongo connection fake, so that is a separate, larger piece.

Written without running locally; CI is the first run.

Refs #1040

@github-actions github-actions Bot added tests Theme parser epic core Core library logic and services ui User interface components and widgets backend Backend database driver execution and queries P3 Low priority / Polish & Enhancements labels Oct 7, 2026
@ZhuchkaTriplesix
ZhuchkaTriplesix merged commit 6b903f2 into dev Oct 8, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend Backend database driver execution and queries core Core library logic and services P3 Low priority / Polish & Enhancements tests Theme parser epic ui User interface components and widgets

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant