Skip to content

Commit

Permalink
mend
Browse files Browse the repository at this point in the history
  • Loading branch information
Javagedes committed Sep 7, 2023
1 parent f8f2f45 commit 63315d8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion edk2toollib/database/tables/instanced_inf_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ def _lib_to_instance(self, library_class_name, scope, library_dict, override_dic
logging.debug(f'scoped library contents: {library_dict}')
logging.debug(f'override dictionary: {override_dict}')
e = f'Cannot find library class [{library_class_name}] for scope [{scope}] when evaluating {self.dsc}'
logging.warn(e)
logging.warning(e)
return None

def _reduce_lib_instances(self, module: str, library_instance_list: list[str]) -> str:
Expand Down
4 changes: 3 additions & 1 deletion tests.unit/database/test_inf_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
##
# ruff: noqa: F811
"""Tests for build an inf file table."""
from pathlib import Path

from common import Tree, empty_tree # noqa: F401
from edk2toollib.database import Edk2DB
from edk2toollib.database.tables import InfTable
Expand Down Expand Up @@ -51,7 +53,7 @@ def test_valid_inf(empty_tree: Tree):
assert len(rows) == 2

for path, library_class in rows:
assert path in [lib1, lib2]
assert path in [Path(lib1).as_posix(), Path(lib2).as_posix()]
assert library_class == "TestCls"

for inf in [lib1, lib2]:
Expand Down
2 changes: 1 addition & 1 deletion tests.unit/database/test_instanced_inf_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def test_library_override(empty_tree: Tree):
library_list = db.connection.cursor().execute(GET_USED_LIBRARIES_QUERY, ("TestDriver1", "IA32"))

for path, in library_list:
assert path in [lib2, lib3]
assert path in [Path(lib2).as_posix(), Path(lib3).as_posix()]

def test_scoped_libraries1(empty_tree: Tree):
"""Ensure that the correct libraries in regards to scoping.
Expand Down

0 comments on commit 63315d8

Please sign in to comment.