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

feat: Duplicate #3396

Merged
merged 5 commits into from Nov 23, 2023
Merged

feat: Duplicate #3396

merged 5 commits into from Nov 23, 2023

Conversation

xoscar
Copy link
Collaborator

@xoscar xoscar commented Nov 23, 2023

This PR adds the duplicate action for tests and test suites, it triggers the confirmation modal before doing the actual duplication

Changes

  • Adds duplication logic for tests and test suites
  • Adds listeners and confirmation modals for duplications

Fixes

Checklist

  • tested locally
  • added new dependencies
  • updated the docs
  • added a test

Loom video

https://www.loom.com/share/6594163f31b24f0388d9d1a21669fc4c

@xoscar xoscar self-assigned this Nov 23, 2023
@xoscar xoscar requested a review from jorgeepc November 23, 2023 18:39
@xoscar xoscar marked this pull request as ready for review November 23, 2023 18:39
Copy link
Contributor

@jorgeepc jorgeepc left a comment

Choose a reason for hiding this comment

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

This is amazing. Great job dude!

@@ -19,6 +20,8 @@ const ConfirmationModal = ({
okText = 'Delete',
cancelText = 'Cancel',
}: IProps) => {
useKeyEvent([Keys.Enter], onConfirm);
Copy link
Contributor

Choose a reason for hiding this comment

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

🚀

@@ -43,8 +43,7 @@ export const useCreateTestSuite = () => useContext(Context);

const CreateTestSuiteProvider = ({children}: IProps) => {
const dispatch = useAppDispatch();
const [create, {isLoading: isLoadingCreate}] = useCreateTestSuiteMutation();
const {runTestSuite, isEditLoading} = useTestSuiteCrud();
Copy link
Contributor

Choose a reason for hiding this comment

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

let's delete the {useCreateTestSuiteMutation} = TracetestAPI.instance; line

@xoscar xoscar merged commit c5c43de into main Nov 23, 2023
38 checks passed
@xoscar xoscar deleted the feat/duplicate branch November 23, 2023 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants