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
[Bug 1182904] Gather plugin version/filename in AAQ #2593
Conversation
strtemp = navigator.plugins[i].name; | ||
if (navigator.plugins[i].version) strtemp += ' ' + navigator.plugins[i].version; | ||
if (navigator.plugins[i].filename) strtemp += ' (' + navigator.plugins[i].filename + ')'; | ||
d = strtemp.replace(/<[^>]+>/ig,''); |
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.
Nit: Pretty sure there should be a space between the comma and the first quote.
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.
that part is copied over from the existing code, but i could change that of course if you like...
Nit: The commit message doesn't conform to our guidelines. That's an issue since it won't work with our tools very well. http://kitsune.readthedocs.org/en/latest/conventions.html#git-commit-messages Can you write tests for this? Amongst other things, it'll help document the expectation of the shape of things you're parsing out for future maintainers. |
hi will, i did change the commit message accoridingly but i'm sorry that i can't write a test for this change, since i'm not knowledgeable enough for that... |
I think I can write test for this! I will try to write a test for this! |
The tests should verify the code is working as intended. What kind of strings are being manipulated here? What kind of objects are being operated on? What possible error situations can occur? |
You can add tests for JS code in kitsune/sumo/static/sumo/js/tests. |
Sorry, have no Idea about Javascript tests! 😞 |
I don't want to merge this without tests. Unfortunately, the state of our JS tests aren't great, so this might be hard to accomplish. For now, I'm going to close this to clean things up. Let me know if you want to work on tests, and I can help you out. |
i've asked around amongst contributors but noone of us will be able to write js tests for this patch - is this something that sumodev could do, since the change in the pull-request itself would be most useful in the support forum? |
No description provided.