Projet

Général

Profil

0001-family-orleans-connector-defines-invoices-dir-path-1.patch

Voir les différences:

Subject: [PATCH] family: orleans connector defines invoices dir path (#15855)

Instead of copying pdf files into the archive.
 passerelle/apps/family/loaders/concerto_orleans.py |  18 ++++++--
 .../management/commands/import_orleans_data.py     |  11 +++--
 tests/data/factures/facture_1502033774.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502033794.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502034197.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502034982.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502037141.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502038829.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502039265.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502041358.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502043515.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1502045601.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602000568.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602002481.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602005406.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602006116.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602009429.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602010615.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602013169.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602015123.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602017319.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602019524.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602021510.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602023571.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602025774.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602028362.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602031264.pdf         |  49 +++++++++++++++++++++
 tests/data/factures/facture_1602031791.pdf         |  49 +++++++++++++++++++++
 tests/data/family_data_orleans.zip                 | Bin 29632 -> 4300 bytes
 tests/test_family.py                               |  27 +++++++++---
 30 files changed, 1315 insertions(+), 15 deletions(-)
 create mode 100644 tests/data/factures/facture_1502033774.pdf
 create mode 100644 tests/data/factures/facture_1502033794.pdf
 create mode 100644 tests/data/factures/facture_1502034197.pdf
 create mode 100644 tests/data/factures/facture_1502034982.pdf
 create mode 100644 tests/data/factures/facture_1502037141.pdf
 create mode 100644 tests/data/factures/facture_1502038829.pdf
 create mode 100644 tests/data/factures/facture_1502039265.pdf
 create mode 100644 tests/data/factures/facture_1502041358.pdf
 create mode 100644 tests/data/factures/facture_1502043515.pdf
 create mode 100644 tests/data/factures/facture_1502045601.pdf
 create mode 100644 tests/data/factures/facture_1602000568.pdf
 create mode 100644 tests/data/factures/facture_1602002481.pdf
 create mode 100644 tests/data/factures/facture_1602005406.pdf
 create mode 100644 tests/data/factures/facture_1602006116.pdf
 create mode 100644 tests/data/factures/facture_1602009429.pdf
 create mode 100644 tests/data/factures/facture_1602010615.pdf
 create mode 100644 tests/data/factures/facture_1602013169.pdf
 create mode 100644 tests/data/factures/facture_1602015123.pdf
 create mode 100644 tests/data/factures/facture_1602017319.pdf
 create mode 100644 tests/data/factures/facture_1602019524.pdf
 create mode 100644 tests/data/factures/facture_1602021510.pdf
 create mode 100644 tests/data/factures/facture_1602023571.pdf
 create mode 100644 tests/data/factures/facture_1602025774.pdf
 create mode 100644 tests/data/factures/facture_1602028362.pdf
 create mode 100644 tests/data/factures/facture_1602031264.pdf
 create mode 100644 tests/data/factures/facture_1602031791.pdf
passerelle/apps/family/loaders/concerto_orleans.py
105 105

  
106 106
    def __init__(self, connector):
107 107
        self.connector = connector
108
        self.invoice_filename_pattern = 'invoices/facture_%s.pdf'
108
        self.invoice_filename_pattern = 'facture_%s.pdf'
109
        self.invoices_dir_filename = 'invoices_location'
109 110

  
110 111
    def clean(self, archive):
111 112
        for filename in ('extract_prcit_personne.csv', 'extract_prcit_famille.csv',
......
166 167
                    Child.objects.get_or_create(family=family,
167 168
                        external_id=child_data['external_id'], defaults=child_data)
168 169

  
170
                print archive.namelist()
171
                if self.invoices_dir_filename not in archive.namelist():
172
                    continue
173

  
169 174
                for invoice_data in family_data.get('invoices') or []:
170 175
                    invoice_filename = self.invoice_filename_pattern % invoice_data['external_id']
176
                    invoices_dir = archive.read(self.invoices_dir_filename)
177
                    invoice_path = os.path.join(invoices_dir, invoice_filename)
178
                    print invoice_path
171 179
                    # create invoice object only if associated pdf exists
172
                    if invoice_filename in archive.namelist():
180
                    if os.path.exists(invoice_path):
181
                        print '%s created' % invoice_path
173 182
                        invoice, created = Invoice.objects.update_or_create(resource=self.connector,
174
                                            family=family, external_id=invoice_data['external_id'], defaults=invoice_data)
175
                        invoice.write_pdf(archive.read(invoice_filename))
183
                            family=family, external_id=invoice_data['external_id'], defaults=invoice_data)
184

  
185
                        invoice.write_pdf(file(invoice_path).read())
176 186

  
177 187
        except Exception, e:
178 188
            self.connector.logger.error('Error occured while importing data: %s', e)
passerelle/apps/family/management/commands/import_orleans_data.py
24 24
from django.core.files.base import File
25 25
from django.core.management.base import BaseCommand, CommandError
26 26

  
27
from family.models import GenericFamily
27
from family.models import GenericFamily, Invoice
28 28

  
29 29
LOCK_FILENAME = os.path.join(tempfile.gettempdir(), 'import-orleans-data.lock')
30 30

  
......
63 63
            fd = open(LOCK_FILENAME, 'w')
64 64
            fcntl.lockf(fd, fcntl.LOCK_EX|fcntl.LOCK_NB)
65 65
            invoices_dir = os.path.join(options['data_dir'], 'factures')
66
            if not os.path.exists(invoices_dir):
67
                raise Exception('Directory "%s" does not exist' % invoices_dir)
66 68
            with zipfile.ZipFile(archive_path, 'a') as archive:
67

  
68
                for invoice_file in os.listdir(invoices_dir):
69
                    if invoice_file.startswith('facture_'):
70
                        archive.write(os.path.join(invoices_dir, invoice_file),
71
                                      'invoices/%s' % invoice_file)
69
                zipinfo = zipfile.ZipInfo('invoices_location')
70
                archive.writestr(zipinfo, invoices_dir)
72 71
            connector.archive.save(options['archive_name'], File(file(archive_path)))
73 72
        except IOError:
74 73
            raise CommandError('Command already running.')
tests/data/factures/facture_1502033774.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-R>'J!a+coIbu6/XX]O4s3-!_++(sMTEXk1TSSYrKn*4NA`6NYml[e`+C?;`@LS!K.r*h#A%*0Fe:2<M3eeM5$$<re_^U54M&!8o`~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1502033794.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>2E&$$d8UCn;@(YOlVZU%!W]gb'DD~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502034197.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>2DMQqf2N$t;@(YOlVZU%!W]g9'D2~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502034982.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>2R0VCdSpLo;@(YOlVZU%!W]gh'DD~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502037141.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-Vkqrii5&k\Us[=tl6'I6`B"65n8O)hKV71UDb!Yqflu;%/S[K:ZK7"*DG\eeGs8on$<LRaK&:4n!fLUH%cW"'asmmHOr-I(D-Jm/~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1502038829.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>[]hHke5Q^q;@(YOlVZU%!W]hW'Dh~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502039265.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>[PT`qePlgr;@(YOlVZU%!W]gW'D;~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502041358.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>0f1ercr::m;@(YOlVZU%!W]fY'Cl~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502043515.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>0fCmGePlgr;@(YOlVZU%!W]f/'CP~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1502045601.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%2)$d>0f:a@e5Q^q;@(YOlVZU%!W]ek'C>~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602000568.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<0JGAjcr::m;@(YOlVZU%!W]fC'Cc~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602002481.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-Vkqr\10PkZnU+/XX]O4s3-!+cY^c'p42aAlb%<qCreRN%QOtYT8^?`"ltVmM5T-]eG=OKds5#]$Cg+,`%+5C5j69o6p,r!P0cpm/~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602005406.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<0JtR=do6Up;@(YOlVZU%!W]e_'C>~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602006116.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 112 >>
25
stream
26
Gap@D_$WG('F"6R5Kj`Jmc!iE<idk@%nJ8$gPGkWl-sN]Nj*a(\0`&_AeJkK*JHQ41Sa-d/+g<Ad@9*O@Tq@K4uX1X22b?`nH5u/%sdjK\f)7K~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001082 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1131
49
%%EOF
tests/data/factures/facture_1602009429.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-Vl\J!a+coI^>&X^EX%qgaJ<JrT!o%3c2/bcE"6qJeZ,1tnb(a*'9r!LoLYE*;D^G/>ARSWmhkn)rEO?G&f;5$$<ee_c/!]t2?"p&~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602010615.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-Vkqrii5&k\Z9p=tl6'I6`B"65n8O)hKV71UDb!Yqflu;%/S[K:\b)4`nTAeeGs8*<ibT1o#nSHJ\N!K/fP-:+c*iG4brQ5.Uq3lM~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602013169.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<1c@1se5Q^q;@(YOlVZU%!W]fX'Cl~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602015123.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-Vkqrii5&k\UsO=tl6'I6`B"65n8O)hKV71UDb!Yqflu;%/S[K:ZK7"*DG\eeGs8on$<LRaK&:4n!fLP;qMlk?I-RmHOr-I(B.gl2~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602017319.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<1cI>"e5Q^q;@(YOlVZU%!W]fs'Cu~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602019524.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<ZnsWqd8UCn;@(YOlVZU%!W]g)'Cu~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602021510.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 111 >>
25
stream
26
Gap@DYmNa((e&Z1*R9Iln,@bk.jj<N!YU-kM"`:]elg;/_VXP;E^9(mUJS`b'[);.%%\fLd,3DDB8.L=j1JXk\Y@Z,"Z<S*hso_'O<tLKb7j%~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001081 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1130
49
%%EOF
tests/data/factures/facture_1602023571.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<1,_!Ke5Q^q;@(YOlVZU%!W]fE'CY~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602025774.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0b-H6'Eri?4%tK_s4=Pk$'k'g5W0=>D1qd"OdA`to+ZJJ+(KoMBP'[R[\LS1fYV0Ep'UcQ<Z"6/6ntn8]$CiQ`JNnIn0N6ceb:65*kL;DpA~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602028362.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 114 >>
25
stream
26
Gap@D0a`Fb&-R>'J!a+coIc86/SJ^@+-<.LO@JmB#*FURAlb$LrKo?67_^A:Ylc#X!F(u:<CQ-/#%84^1A.rLqmgl,MAJL3kSrm,g@'Zp?FlgDo)~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001084 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1133
49
%%EOF
tests/data/factures/facture_1602031264.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<2Dd0Fd8UCn;@(YOlVZU%!W]eq'CG~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/data/factures/facture_1602031791.pdf
1
%PDF-1.3
2
%???? ReportLab Generated PDF document http://www.reportlab.com
3
1 0 obj
4
<< /F1 2 0 R >>
5
endobj
6
2 0 obj
7
<< /BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font >>
8
endobj
9
3 0 obj
10
<< /Contents 7 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 6 0 R /Resources << /Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] >> /Rotate 0 /Trans <<  >> 
11
  /Type /Page >>
12
endobj
13
4 0 obj
14
<< /Outlines 8 0 R /PageMode /UseNone /Pages 6 0 R /Type /Catalog >>
15
endobj
16
5 0 obj
17
<< /Author (anonymous) /CreationDate (D:20161118142737-01'00') /Creator (ReportLab PDF Library - www.reportlab.com) /Keywords () /ModDate (D:20161118142737-01'00') /Producer (ReportLab PDF Library - www.reportlab.com) 
18
  /Subject (unspecified) /Title (untitled) /Trapped /False >>
19
endobj
20
6 0 obj
21
<< /Count 1 /Kids [ 3 0 R ] /Type /Pages >>
22
endobj
23
7 0 obj
24
<< /Filter [ /ASCII85Decode /FlateDecode ] /Length 115 >>
25
stream
26
GapQh0E=F,0U\H3T\pNYT^QKk?tc>IP,;W#U1^23ihPEM_TN+I0SHG`2GgV30Mi%s<R>\X9J.bG8l[Q%1GCR<2Dhm"e5Q^q;@(YOlVZU%!W]g$'Cu~>endstream
27
endobj
28
8 0 obj
29
<< /Count 0 /Type /Outlines >>
30
endobj
31
xref
32
0 9
33
0000000000 65535 f
34
0000000075 00000 n
35
0000000109 00000 n
36
0000000219 00000 n
37
0000000426 00000 n
38
0000000513 00000 n
39
0000000813 00000 n
40
0000000875 00000 n
41
0000001085 00000 n
42
trailer
43
<< /ID 
44
 % ReportLab generated PDF document -- digest (http://www.reportlab.com)
45
 [(\225\345b\271C#420}9\311\365k\266\254) (\225\345b\271C#420}9\311\365k\266\254)]
46
 /Info 5 0 R /Root 4 0 R /Size 9 >>
47
startxref
48
1134
49
%%EOF
tests/test_family.py
221 221
    # all related objects will also be deleted
222 222
    Family.objects.all().delete()
223 223
    filepath = os.path.join(os.path.dirname(__file__), 'data', 'family_data_orleans.zip')
224
    temp_archive_path = os.path.join(os.path.dirname(__file__), 'data', 'family_orleans.zip')
225
    invoices_dir = os.path.join(os.path.dirname(__file__), 'data', 'factures')
224 226
    resource = GenericFamily(title='test orleans',
225 227
            slug='test-orleans', archive=filepath, file_format='concerto_orleans')
226 228
    from family.loaders.concerto_orleans import Loader
227 229
    loader = Loader(resource)
228
    loader.archive = zipfile.ZipFile(filepath)
230
    archive = zipfile.ZipFile(filepath)
231
    with zipfile.ZipFile(temp_archive_path, 'w') as temp_archive:
232
        for element in archive.namelist():
233
            temp_archive.writestr(element, archive.read(element))
234
        zipinfo = zipfile.ZipInfo(loader.invoices_dir_filename)
235
        temp_archive.writestr(zipinfo, invoices_dir)
236
    loader.archive = zipfile.ZipFile(temp_archive_path)
229 237

  
230 238
    families = loader.build_families()
231 239
    assert len(families) == 18
......
269 277
    # and 14 families with no invoices
270 278
    assert len([f for f in families.values() if not f['invoices']]) == 14
271 279

  
280
    resource.archive = filepath
272 281
    resource.save()
273 282

  
274 283
    assert Family.objects.filter(resource=resource).count() == 18
......
277 286
    assert Invoice.objects.filter(resource=resource).count() == 26
278 287
    assert Invoice.objects.filter(resource=resource, total_amount=0).count() == 2
279 288
    assert Invoice.objects.filter(online_payment=True).count() == 26
289
    os.unlink(temp_archive_path)
280 290

  
281 291
def test_orleans_data_import_command():
282 292
    with pytest.raises(CommandError) as error:
......
306 316
    assert Family.objects.filter(resource=resource).count() == 0
307 317
    assert Invoice.objects.filter(resource=resource).count() == 0
308 318

  
319
    old_name = os.path.join(data_dir, 'factures')
320
    new_name = os.path.join(data_dir, 'factures_renamed')
321
    os.rename(old_name, new_name)
322

  
309 323
    with pytest.raises(Exception) as error:
310 324
        call_command('import_orleans_data', data_dir=data_dir,
311 325
                     archive_name='family_data_orleans.zip',
312 326
                     connector='test-orleans')
313
    assert "No such file or directory: '%s/factures'" % data_dir in str(error.value)
327
    assert 'Directory "%s/factures" does not exist' % data_dir in str(error.value)
328
    os.rename(new_name, old_name)
314 329

  
315 330
    # create temporary expected dir for invoices
316
    invoices_dir = os.path.join(data_dir, 'factures')
317
    os.mkdir(invoices_dir)
331
    # invoices_dir = os.path.join(data_dir, 'factures')
332
    # os.mkdir(invoices_dir)
333
    Family.objects.filter(resource=resource).delete()
334
    Invoice.objects.filter(resource=resource).delete()
318 335
    call_command('import_orleans_data', data_dir=data_dir,
319 336
                 archive_name='family_data_orleans.zip',
320 337
                 connector='test-orleans')
321
    os.rmdir(invoices_dir)
338
    # os.rmdir(invoices_dir)
322 339

  
323 340
    assert Family.objects.filter(resource=resource).count() > 0
324 341
    assert Adult.objects.all().count() > 0
325
-