Skip to content

Commit

Permalink
Export all public version classes on package level
Browse files Browse the repository at this point in the history
  • Loading branch information
whimboo committed Apr 21, 2023
1 parent 5009b56 commit c40d78c
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 1 deletion.
11 changes: 11 additions & 0 deletions mozilla_version/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1,12 @@
"""Defines characteristics of Mozilla's version numbers."""

from mozilla_version.gecko import (
DeveditionVersion,
FennecVersion,
FirefoxVersion,
GeckoVersion,
GeckoSnapVersion,
ThunderbirdVersion,
)
from mozilla_version.maven import MavenVersion
from mozilla_version.mobile import MobileVersion
17 changes: 17 additions & 0 deletions mozilla_version/test/test_default_imports.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import pytest

import mozilla_version


@pytest.mark.parametrize('version_type', [
'DeveditionVersion',
'FennecVersion',
'FirefoxVersion',
'GeckoVersion',
'GeckoSnapVersion',
'MavenVersion',
'MobileVersion',
'ThunderbirdVersion',
])
def test_(version_type):
getattr(mozilla_version, version_type)
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ commands =

[flake8]
max-line-length = 99
exclude = .ropeproject,.tox,sandbox,docs,.eggs,*.egg,*.egg-info,setup.py,build/,mozilla_version/test/
exclude = .ropeproject,.tox,sandbox,docs,.eggs,*.egg,*.egg-info,setup.py,build/,mozilla_version/__init__.py,mozilla_version/test/
show-source = True

[pytest]
Expand Down

0 comments on commit c40d78c

Please sign in to comment.