generated from thombashi/python-lib-project-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename package from pyenvinfo to envinfopy
- Loading branch information
Showing
9 changed files
with
40 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,38 @@ | ||
import re | ||
|
||
import pyenvinfo | ||
import envinfopy | ||
|
||
|
||
RE_VERSION = re.compile(r"[0-9]\.[0-9]+\.[0-9]+", re.MULTILINE) | ||
|
||
|
||
class Test_get_envinfo: | ||
def test_normal(self): | ||
envinfo = pyenvinfo.get_envinfo(["pytest", "pyenvinfo"]) | ||
envinfo = envinfopy.get_envinfo(["pytest", "envinfopy"]) | ||
print(envinfo) | ||
|
||
assert len(envinfo["uname"]) >= 10 | ||
assert RE_VERSION.search(envinfo["version"]) | ||
assert RE_VERSION.search(envinfo["pytest version"]) | ||
assert RE_VERSION.search(envinfo["pyenvinfo version"]) | ||
assert RE_VERSION.search(envinfo["envinfopy version"]) | ||
|
||
def test_abnormal_not_installed(self): | ||
envinfo = pyenvinfo.get_envinfo(["not-installed-pkg"]) | ||
envinfo = envinfopy.get_envinfo(["not-installed-pkg"]) | ||
print(envinfo) | ||
|
||
assert len(envinfo["uname"]) >= 10 | ||
assert RE_VERSION.search(envinfo["version"]) | ||
assert envinfo["not-installed-pkg version"] == "not installed" | ||
|
||
def test_abnormal_empty(self): | ||
envinfo = pyenvinfo.get_envinfo([""]) | ||
envinfo = envinfopy.get_envinfo([""]) | ||
|
||
assert envinfo == pyenvinfo.get_envinfo() | ||
assert envinfo == envinfopy.get_envinfo() | ||
|
||
|
||
class Test_dumps: | ||
def test_smoke(self): | ||
output = pyenvinfo.dumps() | ||
output = envinfopy.dumps() | ||
|
||
assert len(output) > 20 | ||
assert RE_VERSION.search(output) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters