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

added week and quarter to persian/farsi #1190

Merged
merged 7 commits into from
Oct 22, 2024
Merged

Conversation

Crimson-Amir
Copy link
Contributor

There was no equivalent of week and quarter in Persian language.
I use this library and I had to use try-except to handle the week and this made me do this contribute.

Copy link

codecov bot commented Oct 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (403c29f) to head (2648f45).
Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #1190   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           10        10           
  Lines         2324      2324           
  Branches       357       357           
=========================================
  Hits          2324      2324           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jadchaar
Copy link
Member

Thanks @Crimson-Amir for the contribution. Mind adding some unit tests?

@jadchaar
Copy link
Member

@Crimson-Amir would it be possible to add some unit tests? Then we can merge this in.

@Crimson-Amir
Copy link
Contributor Author

Sure

@jadchaar
Copy link
Member

Hey @Crimson-Amir thanks for adding tests. Mind running tox -e lint to fix the linting issues?

Copy link
Member

@krisfremen krisfremen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quarter tests are missing, but LGTM otherwise

assert self.locale._format_timeframe("hours", 2) == "2 ساعت"
assert self.locale._format_timeframe("days", 2) == "2 روز"
assert self.locale._format_timeframe("weeks", 2) == "2 هفته"
assert self.locale._format_timeframe("months", 2) == "2 ماه"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing tests for quarters, otherwise 👍

@jadchaar jadchaar merged commit c78e35e into arrow-py:master Oct 22, 2024
20 checks passed
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