8000 test: three wal_test cases still named and commented as crashes but no longer crash · Issue #329 · project-minigraf/minigraf · GitHub
[go: up one dir, main page]

Skip to content
  • test: three wal_test cases still named and commented as crashes but no longer crash #329

    Closed

    Description

    @adityamukho

    Summary

    Several tests in tests/wal_test.rs describe themselves as crash simulations but no longer simulate a crash.

    Background

    When the crash idiom moved from std::mem::forget to real aborting subprocesses, three sites were deliberately converted to a plain drop(db) instead: they were never crash tests. They assert through a live handle throughout, so mem::forget there had been incidental. That judgment was reviewed and is correct.

    What did not follow is the naming and the comments.

    Specifics

    • tests/wal_test.rs:341 — "after crash-reopen"
    • tests/wal_test.rs:376 — "// Crash: skip Drop checkpoint. Nothing is pending though —", which contradicts itself
    • tests/wal_test.rs:383 — "after auto-checkpoint crash"
    • The test name wal_recover_rollback_crash

    Why it matters

    Misnamed tests are how future readers acquire false beliefs about what is covered. A reader scanning for crash-recovery coverage will count these and be wrong.

    Task

    • Rename wal_recover_rollback_crash to describe what it actually does
    • Correct the three comments
    • Check no other test in the file claims a crash it does not perform
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      No labels
      No labels

      Type

      No type

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions

        0