Fossil SCM
Use the editor setting in amend test for interactive edits because it has precedence over both VISUAL and EDITOR.
Commit
cc265caba7c239baf45df83ec57b7eaf68393e7e
Parent
c9fad621f72c44c…
1 file changed
+1
-2
+1
-2
| --- test/amend.test | ||
| +++ test/amend.test | ||
| @@ -374,14 +374,13 @@ | ||
| 374 | 374 | prep-test "final comment" "final content" |
| 375 | 375 | if {[catch {exec which ed} result]} { |
| 376 | 376 | if {$VERBOSE} { protOut "Install ed for interactive comment test: $result" } |
| 377 | 377 | test-comment 5 $UUID "ed required for interactive edit" |
| 378 | 378 | } else { |
| 379 | - set env(EDITOR) "ed -s" | |
| 379 | + fossil settings editor "ed -s" | |
| 380 | 380 | set comment "interactive edited comment" |
| 381 | 381 | fossil_maybe_answer "a\n$comment\n.\nw\nq\n" amend $UUID --edit-comment |
| 382 | - unset env(EDITOR) | |
| 383 | 382 | test-comment 5 $UUID $comment |
| 384 | 383 | } |
| 385 | 384 | |
| 386 | 385 | ######################################## |
| 387 | 386 | # Test: NULL UUID # |
| 388 | 387 |
| --- test/amend.test | |
| +++ test/amend.test | |
| @@ -374,14 +374,13 @@ | |
| 374 | prep-test "final comment" "final content" |
| 375 | if {[catch {exec which ed} result]} { |
| 376 | if {$VERBOSE} { protOut "Install ed for interactive comment test: $result" } |
| 377 | test-comment 5 $UUID "ed required for interactive edit" |
| 378 | } else { |
| 379 | set env(EDITOR) "ed -s" |
| 380 | set comment "interactive edited comment" |
| 381 | fossil_maybe_answer "a\n$comment\n.\nw\nq\n" amend $UUID --edit-comment |
| 382 | unset env(EDITOR) |
| 383 | test-comment 5 $UUID $comment |
| 384 | } |
| 385 | |
| 386 | ######################################## |
| 387 | # Test: NULL UUID # |
| 388 |
| --- test/amend.test | |
| +++ test/amend.test | |
| @@ -374,14 +374,13 @@ | |
| 374 | prep-test "final comment" "final content" |
| 375 | if {[catch {exec which ed} result]} { |
| 376 | if {$VERBOSE} { protOut "Install ed for interactive comment test: $result" } |
| 377 | test-comment 5 $UUID "ed required for interactive edit" |
| 378 | } else { |
| 379 | fossil settings editor "ed -s" |
| 380 | set comment "interactive edited comment" |
| 381 | fossil_maybe_answer "a\n$comment\n.\nw\nq\n" amend $UUID --edit-comment |
| 382 | test-comment 5 $UUID $comment |
| 383 | } |
| 384 | |
| 385 | ######################################## |
| 386 | # Test: NULL UUID # |
| 387 |