Skip to content

Commit 3092492

Browse files
author
rgaudin
authored
Merge pull request #49 from openzim/rgaudin/get_nsc
rename get_namespaces_count with get_namespace_count
2 parents d04494c + 7cf506d commit 3092492

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libzim/wrapper.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,7 @@ cdef class FilePy:
481481
A string containing initials of all namespaces in the file (ex: "-AIMX") """
482482
return self.c_file.getNamespaces().decode("UTF-8", "strict")
483483

484-
def get_namespaces_count(self, str ns) -> int:
484+
def get_namespace_count(self, str ns) -> int:
485485
""" Articles count within a namespace -> int
486486

487487
Returns

tests/test_libzim_file_reader.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ def test_get_article_by_id(reader, article_data):
9696

9797
def test_namespace_count(reader):
9898
namespaces = reader.namespaces
99-
num_articles = sum(reader.get_namespaces_count(ns) for ns in namespaces)
99+
num_articles = sum(reader.get_namespace_count(ns) for ns in namespaces)
100100
assert reader.article_count == num_articles
101101

102102

0 commit comments

Comments
 (0)