mirror of
https://github.com/ivuorinen/nvim-shellspec.git
synced 2026-01-26 11:34:04 +00:00
- Add modern Lua implementation with modular architecture - Implement HEREDOC preservation and smart comment indentation - Create dual implementation (Neovim Lua + VimScript fallback) - Add comprehensive health check and configuration system - Enhance formatting engine with state machine for context awareness - Update documentation with Lua configuration examples - Add memory files for development workflow and conventions
36 lines
828 B
Bash
Executable File
36 lines
828 B
Bash
Executable File
#!/bin/bash
|
|
|
|
Describe "ShellSpec formatting test"
|
|
# This is a top-level comment
|
|
Context "when testing HEREDOC support"
|
|
# Comment inside Context
|
|
It "should preserve HEREDOC formatting"
|
|
# Comment inside It block
|
|
When call cat <<EOF
|
|
This indentation should be preserved
|
|
Even with deeper indentation
|
|
Back to original level
|
|
EOF
|
|
The output should include "preserved"
|
|
End
|
|
|
|
It "should handle quoted HEREDOC"
|
|
When call cat <<'DATA'
|
|
# This comment inside HEREDOC should not be touched
|
|
Some $variable should not be expanded
|
|
DATA
|
|
The output should include "variable"
|
|
End
|
|
End
|
|
|
|
Context "when testing regular formatting"
|
|
# Another context comment
|
|
It "should indent comments properly"
|
|
# This comment should be indented to It level
|
|
When call echo "test"
|
|
# Another comment at It level
|
|
The output should equal "test"
|
|
End
|
|
End
|
|
End
|