Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Create tests for Disabled context menu items for unsaved files / #12806 #13134

Closed
petetnt opened this issue Mar 1, 2017 · 0 comments
Closed

Comments

@petetnt
Copy link
Collaborator

petetnt commented Mar 1, 2017

#12806 was merged without tests, but it might use some.

My post from #12806 outlines the tests as:

test/Menu-test.js sounds like a good place.

Any specific things you need help with the tests? The structure should could be something like:

it("it should disable context menu items when file doesn't exist ", function () {
 // runs create a new file
 // opens context menu
 // checks that all the items are disabled
});
it("it should enable context menu items when file does exist ", function () {
 // runs create a new file and saves it
 // opens context menu
 // checks that all the items are enabled
});
For example check `DocumentCommandHandlers` tests to see how the working set can be manipulated.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants