Skip to content

Commit

Permalink
feat: change tests to new get_last_ref_date code
Browse files Browse the repository at this point in the history
  • Loading branch information
Robso-creator committed Oct 21, 2024
1 parent 7bff4bc commit 9972716
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 123 deletions.
2 changes: 1 addition & 1 deletion src/io/get_last_ref_date.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def main():
table = soup.find('table')
rows = table.find_all('tr')
list_last_modified_at = []

breakpoint()
print('creating dict files url')
for row in rows:
if row.find_all('td'):
Expand Down
21 changes: 21 additions & 0 deletions tests/io/htmls/test_get_last_ref_date.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">

<html>
<head>
<title>Index of /CNPJ/dados_abertos_cnpj</title>
</head>
<body>
<h1>Index of /CNPJ/dados_abertos_cnpj</h1>
<table>
<tr><th valign="top"><img alt="[ICO]" src="/icons/blank.gif"/></th><th><a href="?C=N;O=D">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr>
<tr><th colspan="5"><hr/></th></tr>
<tr><td valign="top"><img alt="[PARENTDIR]" src="/icons/back.gif"/></td><td><a href="/CNPJ/">Parent Directory</a> </td><td> </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-05/">2024-05/</a> </td><td align="right">2024-08-20 14:23 </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-06/">2024-06/</a> </td><td align="right">2024-08-16 09:58 </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-07/">2024-07/</a> </td><td align="right">2024-08-15 15:32 </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-08/">2024-08/</a> </td><td align="right">2024-08-14 11:42 </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-09/">2024-09/</a> </td><td align="right">2024-09-18 16:20 </td><td align="right"> - </td><td> </td></tr>
<tr><td valign="top"><img alt="[DIR]" src="/icons/folder.gif"/></td><td><a href="2024-10/">2024-10/</a> </td><td align="right">2024-10-16 09:16 </td><td align="right"> - </td><td> </td></tr>
<tr><th colspan="5"><hr/></th></tr>
</table>
</body></html>
53 changes: 0 additions & 53 deletions tests/io/htmls/test_get_last_ref_date_all_equal.html

This file was deleted.

Loading

0 comments on commit 9972716

Please sign in to comment.