Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/commands/issue/issue-view.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,11 @@ export const viewCommand = new Command()

const { identifier } = issueData

// Build metadata line with project and milestone
// Build metadata line with state, project and milestone
const metaParts: string[] = []
if (issueData.state) {
metaParts.push(`**State:** ${issueData.state.name}`)
}
if (issueData.project) {
metaParts.push(`**Project:** ${issueData.project.name}`)
}
Expand Down
12 changes: 10 additions & 2 deletions test/commands/issue/__snapshots__/issue-view.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ snapshot[`Issue View Command - With Mock Server Terminal No Comments 1`] = `
stdout:
"# TEST-123: Fix authentication bug in login flow

**State:** In Progress

Users are experiencing issues logging in when their session expires. This affects the main authentication flow and needs to be resolved quickly.

## Steps to reproduce
Expand All @@ -50,6 +52,8 @@ snapshot[`Issue View Command - With No Comments Flag 1`] = `
stdout:
"# TEST-123: Fix authentication bug in login flow

**State:** In Progress

Users are experiencing issues logging in when their session expires.
"
stderr:
Expand All @@ -60,6 +64,8 @@ snapshot[`Issue View Command - With Comments Default 1`] = `
stdout:
"# TEST-123: Fix authentication bug in login flow

**State:** In Progress

Users are experiencing issues logging in when their session expires.

## Comments
Expand Down Expand Up @@ -168,6 +174,8 @@ snapshot[`Issue View Command - With Parent And Sub-issues 1`] = `
stdout:
"# TEST-456: Implement user authentication

**State:** In Progress

Add user authentication to the application.

## Parent
Expand All @@ -190,7 +198,7 @@ snapshot[`Issue View Command - With Project And Milestone 1`] = `
stdout:
"# TEST-789: Add monitoring dashboards

**Project:** Platform Infrastructure Q1 | **Milestone:** Phase 2: Observability
**State:** In Progress | **Project:** Platform Infrastructure Q1 | **Milestone:** Phase 2: Observability

Set up Datadog dashboards for the new service.
"
Expand All @@ -202,7 +210,7 @@ snapshot[`Issue View Command - With Cycle 1`] = `
stdout:
"# TEST-890: Implement rate limiting

**Project:** API Gateway v2 | **Cycle:** Sprint 7
**State:** Todo | **Project:** API Gateway v2 | **Cycle:** Sprint 7

Add rate limiting to the API gateway.
"
Expand Down
Loading