-
Notifications
You must be signed in to change notification settings - Fork 418
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
Flatten left sidebar nested lists #9068
Conversation
What's the target date with this? It will "break" very soon if anyone touches the involved files |
d42bc3f
to
a4a9112
Compare
Conflicting files |
a4a9112
to
eefe1f1
Compare
|
||
expect(conversationsReceivedEvent).not.toHaveBeenCalled() | ||
|
||
// move on past the fetchConversation call | ||
await wrapper.vm.$nextTick() | ||
await wrapper.vm.$nextTick() | ||
|
||
expect(listEl.props('initialisedConversations')).toBe(true) | ||
expect(listEl.props('conversationsList')).toStrictEqual([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't be order of conversations checked and tested for this component here and in other places?
Suitable places, in my opinion:
- initial render (list and search list)
- after list refetching
- after lastActivity changing
- after new conversation creating
- with favorite conversations (1 and more)
I guess, they come from server in the right order, so we could emulate it with:
const sortedConversationList = conversationsList.slice().sort((a, b) => a.lastActivity - b.lastActivity)
and test like this:
conversationArray.wrappers.forEach((conversation, index) => {
expect(conversation.props('displayName').toBe(sortedConversationList[index].displayName)
}
Please check if it works properly, i didn't test it
Would be nice to hear @ShGKme opinion on this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add some fixes in commits below
cc55983
to
0e8a5ff
Compare
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
0e8a5ff
to
9afe1ab
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works fine after the last rebase and flattened. Tested with different searches, mentions, unread notifications, refreshing, on mobile.
There are things to refactor, but we may do it late, as it is urgent and refactoring is not the purpose of the PR.
/backport to stable26
|
The backport to stable26 failed. Please do this backport manually. # Switch to the target branch and update it
git checkout stable26
git pull origin/stable26
# Create the new backport branch
git checkout -b fix/foo-stable26
# Cherry pick the change from the commit sha1 of the change against the default branch
# This might cause conflicts. Resolve them.
git cherry-pick abc123
# Push the cherry pick commit to the remote repository and open a pull request
git push origin fix/foo-stable26 More info at https://docs.nextcloud.com/server/latest/developer_manual/getting_started/development_process.html#manual-backport |
if (to.name !== 'conversation') { | ||
this.$store.dispatch('updateToken', '') | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to be added after #9058 approval
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice catch!
#9058 is a backport, so it should be fixed anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sadly, but no. It's a copied method from deleted file. Patched this in backport already
Regression of: #9068 Signed-off-by: Grigorii Shartsev <grigorii.shartsev@nextcloud.com>
No description provided.