Skip to content

Add wasm test that input prompt using line not character buffering for stdin#146

Draft
ianthomas23 wants to merge 1 commit intomainfrom
test-stdin-commit-msg
Draft

Add wasm test that input prompt using line not character buffering for stdin#146
ianthomas23 wants to merge 1 commit intomainfrom
test-stdin-commit-msg

Conversation

@ianthomas23
Copy link
Copy Markdown
Member

The correct handling in WebAssembly of the input prompt used for commit messages (issue #44) was fixed in cockle in jupyterlite/cockle#309. This PR adds a test to confirm the fix by using a backspace character in the input prompt to delete the previous character, thus confirming that stdin is using line buffering not individual character buffering.

The new test is disabled if not running in WebAssembly. It already worked correctly in a manual test but running it via python's subprocess.run doesn't work without us using something more complicated like an input pipe to send the stdin characters, and that approach cannot work in WebAssembly so we'd have to implement some new workaround and it is not worth the effort.

Closes #44.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.27%. Comparing base (5ec6e88) to head (8816c78).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #146      +/-   ##
==========================================
+ Coverage   88.22%   88.27%   +0.05%     
==========================================
  Files          61       61              
  Lines        3065     2730     -335     
  Branches      330      330              
==========================================
- Hits         2704     2410     -294     
+ Misses        361      320      -41     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Prompt to enter commit message doesn't fully work in the JupyterLite terminal

1 participant