/usr/lib/python2.7/dist-packages/openpyxl/reader/tests/test_strings.py is in python-openpyxl 2.4.9-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | # Copyright (c) 2010-2017 openpyxl
# package imports
from openpyxl.reader.strings import read_string_table
from openpyxl.tests.helper import compare_xml
def test_read_string_table(datadir):
datadir.chdir()
src = 'sharedStrings.xml'
with open(src) as content:
assert read_string_table(content.read()) == [
u'This is cell A1 in Sheet 1', u'This is cell G5']
def test_empty_string(datadir):
datadir.chdir()
src = 'sharedStrings-emptystring.xml'
with open(src) as content:
assert read_string_table(content.read()) == [u'Testing empty cell', u'']
def test_formatted_string_table(datadir):
datadir.chdir()
src = 'shared-strings-rich.xml'
with open(src) as content:
assert read_string_table(content.read()) == [
u'Welcome',
u'to the best shop in town',
u" let's play "
]
|