Skip to content
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 tests for parseDurationString() #338

Merged
merged 1 commit into from
Jun 15, 2020
Merged

Add tests for parseDurationString() #338

merged 1 commit into from
Jun 15, 2020

Conversation

wb9688
Copy link
Contributor

@wb9688 wb9688 commented May 30, 2020

  • I carefully read the contribution guidelines and agree to them.
  • I have tested the API against NewPipe.
  • I agree to create a pull request for NewPipe as soon as possible to make it compatible with the changed API.

I added some tests for parseDurationString() and found out that apparently the days behavior was already broken, however YouTube doesn't seem to use days anymore.

@wb9688 wb9688 added this to the 0.19.6 milestone Jun 14, 2020
@TobiGr
Copy link
Member

TobiGr commented Jun 14, 2020

@Redirion you approved this PR although you asked to include the changes from #345. I think you suggested changes are good. Is there a reason which I missed to not adopt them?

@wb9688
Copy link
Contributor Author

wb9688 commented Jun 14, 2020

@TobiGr: My personal reason would be that the function that calls it returns a long anyway, plus the speed difference is pretty much negligible I think.

@Redirion
Copy link
Member

@TobiGr
I didn't notice the pr earlier (or more specific that it included a fix). It is good to merge.

@wb9688 think of 32bit arm entry level phones. Long arithmetics should be avoided if not needed. 100 negligible optimizations could make a feelable difference. :)

My PR did also change the return type.

@wb9688
Copy link
Contributor Author

wb9688 commented Jun 15, 2020

@Redirion
Copy link
Member

Long arithmetics on a 32bit cpu require more ressources and operations. Storing and reading it as long should not be an issue.

@TobiGr TobiGr merged commit 92f6754 into TeamNewPipe:dev Jun 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants