@@ -255,7 +255,8 @@ func TestCreateInteractive(t *testing.T) {
255255 t .Setenv ("VISUAL" , "" )
256256 t .Setenv ("EDITOR" , script )
257257
258- injectStdin (t , "My Bug\n e\n \n \n \n " )
258+ // Only title + body "e" — no labels/assignees/milestone prompts should appear.
259+ injectStdin (t , "My Bug\n e\n " )
259260 _ = captureStdout (t , func () {
260261 if err := createCmd .RunE (createCmd , nil ); err != nil {
261262 t .Fatalf ("unexpected error: %v" , err )
@@ -275,6 +276,35 @@ func TestCreateInteractive(t *testing.T) {
275276 }
276277 })
277278
279+ t .Run ("body e with editor skips labels assignees milestone prompts" , func (t * testing.T ) {
280+ parent := makeProjectDir (t , nil )
281+ chdirTo (t , parent )
282+ resetCreateFlag (t )
283+
284+ script := filepath .Join (t .TempDir (), "editor.sh" )
285+ if err := os .WriteFile (script , []byte (
286+ "#!/bin/sh\n cat > \" $1\" <<'EOF'\n ---\n title: My Bug\n state: open\n ---\n EOF\n " ,
287+ ), 0755 ); err != nil {
288+ t .Fatal (err )
289+ }
290+ t .Setenv ("VISUAL" , "" )
291+ t .Setenv ("EDITOR" , script )
292+
293+ // If Labels/Assignees/Milestone prompts were shown, this input would
294+ // block waiting for three more lines. Completing without hanging
295+ // confirms they are skipped.
296+ injectStdin (t , "My Bug\n e\n " )
297+ _ = captureStdout (t , func () {
298+ if err := createCmd .RunE (createCmd , nil ); err != nil {
299+ t .Fatalf ("unexpected error: %v" , err )
300+ }
301+ })
302+
303+ if files := readMDFiles (t , openIssuesDir (t , parent )); len (files ) != 1 {
304+ t .Errorf ("expected 1 file, got %d" , len (files ))
305+ }
306+ })
307+
278308 t .Run ("T-number increments from existing issues" , func (t * testing.T ) {
279309 parent := makeProjectDir (t , []issueFixture {
280310 {"T1-existing.md" , issue.Issue {Title : "Existing" , State : "open" }},
0 commit comments