Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update assign to username for status DONE #1015

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
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
3 changes: 2 additions & 1 deletion __tests__/Unit/Components/Tasks/Card.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -274,11 +274,12 @@ describe('Task card', () => {
expect(assignToText).toBeInTheDocument();
});

it('Should not render "Assign to username" button when parent issue has an assignee and is open, the task status is "Completed" and has not been assigned', function () {
it('Should not render "Assign to username" button when parent issue has an assignee and is open, the task status is "Done" and has not been assigned', function () {
const PROPS = {
...DEFAULT_PROPS,
content: {
...DEFAULT_PROPS.content,
status: 'DONE',
assignee: undefined,
github: {
issue: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/tasks/card/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ const Card: FC<CardProps> = ({
const hasIssueAssignee = () => cardDetails.github?.issue.assignee ?? false;
const hasTaskAssignee = () => cardDetails.assignee ?? false;
const isIssueClosed = () => cardDetails.github?.issue?.status === 'closed';
const isTaskComplete = () => cardDetails.status === COMPLETED;
const isTaskComplete = () => cardDetails.status === DONE;
Copy link
Member

@vinit717 vinit717 Nov 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line seems to be uncovered as you provide this coverage

image


const showAssignButton = () =>
hasIssueAssignee() &&
Expand Down
Loading