- Deleted createEventFromEvent() because the event-specific menu no longer has a menu item that creates another event.
- Deleted createTodoFromTodo() for the same reason.
- Switched away from findChild() because menu items no longer have object names. Switched to C-locale item text; since it is key to i18n, it should be stable.
Details
- Reviewers
mlaurent
Run koeventpopupmenutest.
Diff Detail
- Repository
- R210 KOrganizer
- Branch
- fixtest (branched from master)
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 26814 Build 26832: arc lint + arc unit
src/autotests/koeventpopupmenutest.cpp | ||
---|---|---|
222 | not sure that it"s a good idea to test exact text as it can be change by KF5 etc. |
src/autotests/koeventpopupmenutest.cpp | ||
---|---|---|
222 | Can KF5 change the text? I think that for these menu items it is defined in KOEventPopupMenu::appendEditOnlyItems() |
src/autotests/koeventpopupmenutest.cpp | ||
---|---|---|
222 | Indeed it's define here but I think it's not real useful to test text directly. |
src/autotests/koeventpopupmenutest.cpp | ||
---|---|---|
222 | Perhaps the entire defaultMenuEventVisible() function should be deleted? The old code checked that the "create note" and "create todo" items were visible, but createTodoFromEvent() and createNoteFromEvent() have already tested that. The old code also tested that the "create event" item exists but is not visible -- that is an implementation detail of KOEventPopupMenu, and seems like a poor test to me. I added tests for the existence of the current default menu items, because I thought it was in the spirit of the old code, but my new tests don't check that the items actually do anything, so they are nearly pointless. I'd like to delete both defaultMenuTodoVisible() and defaultMenuEventVisible(). |