• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

openSUSE / agama / 7288508458
72%

Build:
DEFAULT BRANCH: master
Ran 21 Dec 2023 01:07PM UTC
Jobs 3
Files 658
Run time 30s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Dec 2023 01:04PM UTC coverage: 74.758% (-0.002%) from 74.76%
7288508458

push

github

web-flow
Display most representative country in timezone selector (#946)

## Problems

Problem 1.

In the timezone selector the countries are only displayed if they are
part of the name of the timezone (eg. America/Argentina/Buenos_Aires).
In most cases, the name of the timezone includes only the global region
and a concrete city (eg. Europe/Madrid). That makes hard to find the
right timezone since the most intuitive mechanism (typing the name of
the user country in the search box) is usually useless.


![spain-old](https://github.com/openSUSE/agama/assets/3638289/e51c9eac-09ec-471e-af75-e03b4ba5a0e2)

Problem 2.

There are some duplicated or controversial timezones that are not
associated to any country. For more details [this
gist](https://gist.github.com/ancorgs/8bd5f42ea847e1ba7590bc7e3d54cdad).


![buenos_aires-old](https://github.com/openSUSE/agama/assets/3638289/b45e0dd2-4483-485b-b050-c8cac08a9b3c)

## Solution

Add the "most representative country" to each timezone and display that
in the UI. That information is read from the file
`/usr/share/zoneinfo/zone.tab`.

That makes it easier to find timezones.


![spain-new](https://github.com/openSUSE/agama/assets/3638289/cb4ecafc-303c-4c28-94d4-33570a6bfc5d)

Timezones without a country (except those that really make sense) are
filtered out. That removes controversy and duplicates.


![buenos_aires-new](https://github.com/openSUSE/agama/assets/3638289/4a221099-ec78-4626-8005-c76a42b1f1dd)

Works even for the two timezones that have a different identifier at
langtable and at `zone.tab`. Again, see the [previously mentioned
gist](https://gist.github.com/ancorgs/8bd5f42ea847e1ba7590bc7e3d54cdad).


![rangoon-new](https://github.com/openSUSE/agama/assets/3638289/8239362b-ae3b-4848-842f-98bbf8fad070)

## Testing

- Added new unit tests
- Tested manually (as shown in the screenshots)

1413 of 2163 branches covered (0.0%)

Branch coverage included in aggregate %.

11 of 16 new or added lines in 4 files covered. (68.75%)

52 existing lines in 3 files now uncovered.

15966 of 21084 relevant lines covered (75.73%)

21.26 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
1
17.31
0.0% web/src/client/l10n.js
4
0.0
0.0% rust/agama-dbus-server/src/locale.rs

Uncovered Existing Lines

Lines Coverage ∆ File
4
80.56
0.0% rust/agama-locale-data/src/lib.rs
19
16.67
0.0% web/web/src/client/l10n.js
29
0.0
0.0% rust/agama-dbus-server/src/locale.rs
Subprojects
ID Flag name Job ID Ran Files Coverage
1 web 7288508458.1 21 Dec 2023 01:07PM UTC 293
73.85
GitHub Action Run
1 service 7277578298.1 20 Dec 2023 03:40PM UTC 304
84.98
GitHub Action Run
1 rust 7246554818.1 18 Dec 2023 10:12AM UTC 61
40.45
GitHub Action Run
Source Files on build 7288508458
  • Tree
  • List 658
  • Changed 8
  • Source Changed 2
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #7288508458
  • 20c3aa3d on github
  • Prev Build on master (#7277578298)
  • Next Build on master (#7288508462)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc