Fix tests

This commit is contained in:
Ivan Kravets
2020-11-11 20:52:23 +02:00
parent 0f5d2d6821
commit ae7b8f9ecf
2 changed files with 5 additions and 3 deletions

2
docs

Submodule docs updated: a3209b7fbb...0e3e5dd7eb

View File

@ -236,7 +236,9 @@ def test_global_lib_update_check(clirunner, validate_cliresult):
result = clirunner.invoke(cmd_lib, ["-g", "update", "--dry-run", "--json-output"])
validate_cliresult(result)
output = json.loads(result.output)
assert set(["ESPAsyncTCP", "NeoPixelBus"]) == set(lib["name"] for lib in output)
assert set(["Adafruit PN532", "ESPAsyncTCP", "NeoPixelBus"]) == set(
lib["name"] for lib in output
)
def test_global_lib_update(clirunner, validate_cliresult):
@ -256,7 +258,7 @@ def test_global_lib_update(clirunner, validate_cliresult):
result = clirunner.invoke(cmd_lib, ["-g", "update"])
validate_cliresult(result)
assert result.output.count("[Detached]") == 1
assert result.output.count("[Up-to-date]") == 15
assert result.output.count("[Up-to-date]") == 14
# update unknown library
result = clirunner.invoke(cmd_lib, ["-g", "update", "Unknown"])