htmlcmp 1.0.8__tar.gz → 1.0.10__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: htmlcmp
3
- Version: 1.0.8
3
+ Version: 1.0.10
4
4
  Summary: Compare HTML files by rendered output
5
5
  Author: Andreas Stefl
6
6
  Maintainer-email: Andreas Stefl <stefl.andreas@gmail.com>
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "htmlcmp"
3
- version = "1.0.8"
3
+ version = "1.0.10"
4
4
  description = "Compare HTML files by rendered output"
5
5
  classifiers = []
6
6
  authors = [
@@ -44,16 +44,16 @@ def compare_html(a, b, browser=None, diff_output=None):
44
44
  def compare_files(a, b, **kwargs):
45
45
  if filecmp.cmp(a, b):
46
46
  return True
47
- if a.endswith(".json"):
47
+ if a.suffix == ".json":
48
48
  return compare_json(a, b)
49
- if a.endswith(".html"):
49
+ if a.suffix == ".html":
50
50
  return compare_html(a, b, **kwargs)
51
51
 
52
52
 
53
53
  def comparable_file(path):
54
- if path.endswith(".json"):
54
+ if path.suffix == ".json":
55
55
  return True
56
- if path.endswith(".html"):
56
+ if path.suffix == ".html":
57
57
  return True
58
58
  return False
59
59
 
@@ -68,8 +68,8 @@ def submit_compare_dirs(a, b, executor, diff_output=None, **kwargs):
68
68
  "right_dirs_missing": [],
69
69
  }
70
70
 
71
- left = sorted(a.iterdir())
72
- right = sorted(b.iterdir())
71
+ left = sorted(p.name for p in a.iterdir())
72
+ right = sorted(p.name for p in b.iterdir())
73
73
 
74
74
  left_files = sorted(
75
75
  [name for name in left if (a / name).is_file() and comparable_file(a / name)]
@@ -49,8 +49,8 @@ class Observer:
49
49
  def init_compare(a, b):
50
50
  common_path = a / Config.path_a
51
51
 
52
- left = sorted(a.iterdir())
53
- right = sorted(b.iterdir())
52
+ left = sorted(p.name for p in a.iterdir())
53
+ right = sorted(p.name for p in b.iterdir())
54
54
 
55
55
  common = [name for name in left if name in right]
56
56
 
@@ -139,8 +139,8 @@ def root():
139
139
  def print_tree(a, b):
140
140
  common_path = a / Config.path_a
141
141
 
142
- left = sorted(a.iterdir())
143
- right = sorted(b.iterdir())
142
+ left = sorted(p.name for p in a.iterdir())
143
+ right = sorted(p.name for p in b.iterdir())
144
144
 
145
145
  left_files = sorted(
146
146
  [
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: htmlcmp
3
- Version: 1.0.8
3
+ Version: 1.0.10
4
4
  Summary: Compare HTML files by rendered output
5
5
  Author: Andreas Stefl
6
6
  Maintainer-email: Andreas Stefl <stefl.andreas@gmail.com>
File without changes
File without changes
File without changes