Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Adding e2e tests, implemented in Cypress, for basic user-to-user messaging functionality.#1517

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
Green125 wants to merge20 commits intokiwiirc:master
base:master
Choose a base branch
Loading
fromGreen125:master

Conversation

@Green125
Copy link

@Green125Green125 commentedApr 6, 2021
edited
Loading

Also, setting up those tests to run on each push to the master branch of the remote.

Notes:

  1. We have set up the tests such that the Web IRC Gateway, Kiwi IRC (built from the source code of the commit that triggers the GH Action workflow), and the tests themselves all run in the job. The former two are run in background processes.

  2. We accomplish having the two users communicate in the tests via running userOne.js in a background process, and using polling code (always with timeouts) in our Cypress code.

  3. We added the e2e tests as a separate GH Action workflow. We are glad, however, to refactor to combine them into the existing "push" workflow, if that would be preferred by the maintainers of this repo.

  4. As part of the commits in this PR, we validated that the tests we are requesting to contribute do in fact break when the messaging functionality of Kiwi IRC's Vue.js source code is intentionally (temporarily) broken.

That validation is demonstrated in these 3 workflow runs, and the commits with which they are associated:


Please let me know if any questions/comments/concerns and I'll be happy to respond promptly.

Allison added20 commitsApril 4, 2021 21:42
TODO: resolve any issues and then integrate tests into existing push.yml workflow file
… intentionally (temporarily) broken"This reverts commit9a05c4c.
…ality (validating lowering retries works correctly)"This reverts commit7512e7e.
… file be set up for running locally.Reason for this is futureproofing this pipeline configuration against other changes in the config.json filefor Kiwi IRC.
@Shillos
Copy link

I don't think everyone would want e2e on their kiwi, but why not just make it as a plugin, though we have an e2e plugin called plugin-olmhttps://github.com/kiwiirc/plugin-olm maybe work on that might help to improve it better?! Not that I'm against the idea, but consider if kiwi has this then users of mirc / adiirc must have it too or other clients.

@Green125
Copy link
Author

@Shillos Thank you for your feedback on this.

Based on the plugin you mention there, it looks like you are thinking of 'e2e' in the sense of end to end encryption. A clarification: 'e2e' here means end to end tests, not end to end encryption.

We added functional tests that run in the pipeline, using a framework called Cypress, similar to Selenium, etc.

This PR isn't related to encryption.

@Shillos
Copy link

Shillos commentedApr 6, 2021
edited
Loading

My mistake then! :-) After you said selenium then I realized what you meant by it. Ok, I looked it up! it's just that you said e3e most people will think just the same as the end to end for the encryption. So what exactly are these tests for? This isn't like CircleCi i guess!

Green125 reacted with thumbs up emoji

@prawnsalad
Copy link
Member

@Green125 Hi! This is awesome - Cypress is something that's been on my radar and wanted to get integrated for a while. I'll be going through this this week and will drop a comment/review. Thank you!

Green125 reacted with thumbs up emoji

@Green125
Copy link
Author

@Shillos Not a worry :)

@Green125
Copy link
Author

@prawnsalad thank you!

@prawnsalad
Copy link
Member

Firstly, thanks for this. I've taken some time to get to it but I've finally managed to glance over it.

Some points re. integration:

  • We use yarn to install kiwi and run scripts, not npm. otherwise different lockfiles will be used
  • Cypress test files seem to all use their own linting+prettier which is different than the rest of the project, can they not be sharing the same configs since eslint conf is in the root project folder?
  • It's connecting freenode, can we have it setup a quick IRCd locally to speed things up and not spam third party networks? ngircd is a single binary and single config file - it could run in the background.

Some notes on the tests themselves

What may be easier and will definitely be more reliable in a test setting, is using the kiwi API to simulate incoming IRC traffic. iekiwi.state.getActiveNetwork().ircClient.connection.addReadBuffer(':user1!user@host.com PRIVMSG user2 :Greetings') to simulateuser1 sending a PM touser2. This would also mean that only 1 test instance needs to run.

Some selectors should be more specific, scoped to the components it's looking under. ie.https://github.com/kiwiirc/kiwiirc/pull/1517/files?file-filters%5B%5D=.conf&file-filters%5B%5D=.js&file-filters%5B%5D=.json&file-filters%5B%5D=.lock&file-filters%5B%5D=.sh&file-filters%5B%5D=.yml&file-filters%5B%5D=dotfile#diff-fe50c9b85061ba8156472f54025d7b3886aebb43084f3715999b7b8a390b37b1R85 could look under.kiwi-welcome-simple-form

@Green125
Copy link
Author

Firstly, thanks for this. I've taken some time to get to it but I've finally managed to glance over it.

Some points re. integration:

  • We use yarn to install kiwi and run scripts, not npm. otherwise different lockfiles will be used
  • Cypress test files seem to all use their own linting+prettier which is different than the rest of the project, can they not be sharing the same configs since eslint conf is in the root project folder?
  • It's connecting freenode, can we have it setup a quick IRCd locally to speed things up and not spam third party networks? ngircd is a single binary and single config file - it could run in the background.

Some notes on the tests themselves

What may be easier and will definitely be more reliable in a test setting, is using the kiwi API to simulate incoming IRC traffic. iekiwi.state.getActiveNetwork().ircClient.connection.addReadBuffer(':user1!user@host.com PRIVMSG user2 :Greetings') to simulateuser1 sending a PM touser2. This would also mean that only 1 test instance needs to run.

Some selectors should be more specific, scoped to the components it's looking under. ie.https://github.com/kiwiirc/kiwiirc/pull/1517/files?file-filters%5B%5D=.conf&file-filters%5B%5D=.js&file-filters%5B%5D=.json&file-filters%5B%5D=.lock&file-filters%5B%5D=.sh&file-filters%5B%5D=.yml&file-filters%5B%5D=dotfile#diff-fe50c9b85061ba8156472f54025d7b3886aebb43084f3715999b7b8a390b37b1R85 could look under.kiwi-welcome-simple-form

Thank you for the excellent and detailed feedback!

I will address the items you listed, push commits to the branch for this PR, and post a message here once that's done.

@prawnsalad
Copy link
Member

@Green125 nice, if you want to discuss over IRC (i know youve PMd already...) give me a poke and I'll be glad to

@emilymgalore
Copy link

emilymgalore commentedAug 29, 2022
edited
Loading

@ItsOnlyBinary Hello, I've spoken with Illmari and I'm looking to take over this PR and complete it. I can get this done and merged. What's the best way to discuss this with you?

@ItsOnlyBinary
Copy link
Collaborator

@emilymgalore hey, sounds great, you can either discuss here, or poke me on irc.libera,chat #kiwiirc

Either ask@Green125 to add you to their fork so you can continue to push to the same branch, or pull the branch to your fork and create a new pull request

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@Green125@Shillos@prawnsalad@emilymgalore@ItsOnlyBinary

[8]ページ先頭

©2009-2025 Movatter.jp