How to use the pylightxl.writexl.new_sharedStrings_text function in pylightxl

To help you get started, we’ve selected a few pylightxl examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github PydPiper / pylightxl / test / test_writexl.py View on Github external
db.add_ws('Sheet1', {'A1': {'v': 'text1', 'f': '', 's': ''},
                             'A2': {'v': 'text2', 'f': '', 's': ''},
                             'A3': {'v': ' text3', 'f': '', 's': ''},
                             'A6': {'v': 'text4', 'f': '', 's': ''},
                             })

        db.add_ws('Sheet2', {'A4': {'v': 'text5 ', 'f': '', 's': ''},
                             'A5': {'v': ' text6 ', 'f': '', 's': ''},
                             'A6': {'v': 'text4', 'f': '', 's': ''},
                             })

        # process the sharedStrings, see dev note why this is done this way inside new_worksheet_text
        _ = new_worksheet_text(db, 'Sheet1')
        _ = new_worksheet_text(db, 'Sheet2')

        self.assertEqual(new_sharedStrings_text(db), xml_base.format(sharedString_len=6 ,many_tag_si=many_tag_si))