-
-
Notifications
You must be signed in to change notification settings - Fork 386
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
Add real players to test suite #6319
Conversation
personally, i'm super excited about this because it'll help us test more things! that said, i do want to point out a potential pitfall: since minosoft is an open source project, it may lag behind in protocol support for new versions or even be abandoned completely. that would mean our player-related tests might not always be able to run on the latest versions immediately. one future alternative would be using the vanilla client prismlauncher, but the "connect to server on launch" option is currently broken. i think once that is fixed (see PrismLauncher/PrismLauncher#1164), we could feasibly switch to this method instead. |
I don't know if this would necessarily be needed, as we should currently be using EasyMock to mock a player instance with what we need. Njol did this in the past. It's certainly cool, but it relys on a third party application and forces the tests to be in offline mode which isn't a good thing for other tests, and it's security of the clients is also reliant on the third party. |
definitely valid points. I think there is still value in this but i'd love to work on it some more and see what others think. could you pls elaborate on offline mode being bad for other tests? |
UUID tests, skull tests, skin tests, server list syntaxes, player comparison, etc. |
Do you still intend to work on this? |
yes, I think I have a new approach that addresses lime's concerns. We can add it as a new test mode so that some tests can run in online mode and some can run with players. for example:
|
It has now been 11 months with no updates, so I'm closing for inactivity @Pikachu920 |
Description
this PR adds real players to the test suite. the aim it to allow us to test complex things that require players and may not be possible or feasible to mock (e.g parsing uuids 😆). it works by downloading an open-source minecraft implementation Minosoft. a few headless minosoft instances are started in the background and are instructed to join the test server. the test server waits for them to connect before running the tests.
this is currently passing with the
quickTest
task on my win10 machine but not much else.Target Minecraft Versions: any
Requirements: none
Related Issues: none