You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
because I'm calling build with --no-isolation I'm using during all processes only locally installed modules
install .whl file in </install/prefix> using installer module
run pytest with $PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>
build is performed in env which is cut off from access to the public network (pytest is executed with -m "not network")
Here is pytest output:
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib64/python3.10/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages+ /usr/bin/pytest -ra -m 'not network'==================================================================================== test session starts ====================================================================================platform linux -- Python 3.10.14, pytest-8.2.1, pluggy-1.5.0rootdir: /home/tkloczko/rpmbuild/BUILD/cssutils-2.11.0configfile: pytest.iniplugins: typeguard-4.2.1, jaraco.test-5.4.0collected 457 items / 2 deselected / 455 selectedcssutils/__init__.py . [ 0%]cssutils/css/cssstyledeclaration.py .... [ 1%]cssutils/tests/test_codec.py ...... [ 2%]cssutils/tests/test_csscharsetrule.py .......... [ 4%]cssutils/tests/test_csscomment.py ....... [ 6%]cssutils/tests/test_cssfontfacerule.py ........... [ 8%]cssutils/tests/test_cssimportrule.py .............. [ 11%]cssutils/tests/test_cssmediarule.py ................. [ 15%]cssutils/tests/test_cssnamespacerule.py .......... [ 17%]cssutils/tests/test_csspagerule.py .............. [ 20%]cssutils/tests/test_cssproperties.py ... [ 21%]cssutils/tests/test_cssrule.py .... [ 22%]cssutils/tests/test_cssrulelist.py .. [ 22%]cssutils/tests/test_cssstyledeclaration.py ........................ [ 27%]cssutils/tests/test_cssstylerule.py ............ [ 30%]cssutils/tests/test_cssstylesheet.py ............................ [ 36%]cssutils/tests/test_cssunknownrule.py ....... [ 38%]cssutils/tests/test_cssutils.py FFF..... [ 40%]cssutils/tests/test_cssutilsimport.py . [ 40%]cssutils/tests/test_cssvalue.py xxxxxxxxxxxxxxxxxxxxx [ 44%]cssutils/tests/test_cssvariablesdeclaration.py ......... [ 46%]cssutils/tests/test_cssvariablesrule.py .......... [ 49%]cssutils/tests/test_domimplementation.py .... [ 49%]cssutils/tests/test_encutils.py ....... [ 51%]cssutils/tests/test_errorhandler.py ... [ 52%]cssutils/tests/test_helper.py ..... [ 53%]cssutils/tests/test_marginrule.py ........ [ 54%]cssutils/tests/test_medialist.py ......... [ 56%]cssutils/tests/test_mediaquery.py .... [ 57%]cssutils/tests/test_parse.py .............. [ 60%]cssutils/tests/test_prodparser.py ................. [ 64%]cssutils/tests/test_profiles.py ........xxxxxx.............xxxxx [ 71%]cssutils/tests/test_properties.py .. [ 72%]cssutils/tests/test_property.py ........ [ 73%]cssutils/tests/test_scripts_csscombine.py F. [ 74%]cssutils/tests/test_selector.py ........ [ 76%]cssutils/tests/test_selectorlist.py ..... [ 77%]cssutils/tests/test_serialize.py ............................. [ 83%]cssutils/tests/test_settings.py . [ 83%]cssutils/tests/test_stylesheet.py . [ 83%]cssutils/tests/test_tokenize2.py ............. [ 86%]cssutils/tests/test_util.py ..................... [ 91%]cssutils/tests/test_value.py .....................xxxxxxxxxx [ 98%]cssutils/tests/test_x.py x [ 98%]encutils/__init__.py . [ 98%]examples/website.py ...... [100%]========================================================================================= FAILURES ==========================================================================================_______________________________________________________________________________ TestCSSutils.test_parseString _______________________________________________________________________________self = <cssutils.tests.test_cssutils.TestCSSutils object at 0x7efe6fc2ee90> def test_parseString(self): "cssutils.parseString()" s = cssutils.parseString( self.exp, media='handheld, screen', title='from string' ) assert isinstance(s, cssutils.css.CSSStyleSheet) assert s.href is None assert self.exp.encode() == s.cssText assert 'utf-8' == s.encoding assert 'handheld, screen' == s.media.mediaText assert 'from string' == s.title assert self.exp.encode() == s.cssText ir = s.cssRules[0] assert 'import/import2.css' == ir.href irs = ir.styleSheet assert isinstance(irs, cssutils.css.CSSStyleSheet) href = basetest.get_sheet_filename('import.css') href = cssutils.helper.path2url(href) s = cssutils.parseString(self.exp, href=href) assert href == s.href ir = s.cssRules[0] assert 'import/import2.css' == ir.href irs = ir.styleSheet assert isinstance(irs, cssutils.css.CSSStyleSheet) assert (
> irs.cssText == b'@import "../import3.css";\n' b'@import "import-impossible.css" print;\n.import2 {\n' b' /* sheets/import2.css */\n' b' background: url(http://example.com/images/example.gif);\n' b' background: url(//example.com/images/example.gif);\n' b' background: url(/images/example.gif);\n' b' background: url(images2/example.gif);\n' b' background: url(./images2/example.gif);\n' b' background: url(../images/example.gif);\n' b' background: url(./../images/example.gif)\n' b' }' )E AssertionErrorcssutils/tests/test_cssutils.py:56: AssertionError________________________________________________________________________________ TestCSSutils.test_parseFile ________________________________________________________________________________self = <cssutils.tests.test_cssutils.TestCSSutils object at 0x7efe6fc2c3d0>, monkeypatch = <_pytest.monkeypatch.MonkeyPatch object at 0x7efe6f738970> def test_parseFile(self, monkeypatch): "cssutils.parseFile()" # name if used with open, href used for @import resolving name = basetest.get_sheet_filename('import.css') href = cssutils.helper.path2url(name)
> s = cssutils.parseFile(name, href=href, media='screen', title='from file')cssutils/tests/test_cssutils.py:81:_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/__init__.py:166: in func return getattr(CSSParser(), name)(*args, **kwargs)_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _self = <cssutils.parse.CSSParser object at 0x7efe6f73ada0>filename = PosixPath('/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/import.css'), encoding = Nonehref = 'file:/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/import.css', media = 'screen', title = 'from file'validate = None def parseFile( self, filename, encoding=None, href=None, media=None, title=None, validate=None ): """Retrieve content from `filename` and parse it. Errors may be raised (e.g. IOError). :param filename: of the CSS file to parse, if no `href` is given filename is converted to a (file:) URL and set as ``href`` of resulting stylesheet. If `href` is given it is set as ``sheet.href``. Either way ``sheet.href`` is used to resolve e.g. stylesheet imports via @import rules. :param encoding: Value ``None`` defaults to encoding detection via BOM or an @charset rule. Other values override detected encoding for the sheet at `filename` including any imported sheets. :returns: :class:`~cssutils.css.CSSStyleSheet`. """ if not href: # prepend // for file URL, urllib does not do this? # href = u'file:' + urllib.pathname2url(os.path.abspath(filename)) href = path2url(filename)
> with open(filename, 'rb') as fd:E FileNotFoundError: [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/import.css'../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/parse.py:182: FileNotFoundError________________________________________________________________________________ TestCSSutils.test_parseUrl _________________________________________________________________________________self = <urllib.request.FileHandler object at 0x7efe6f72d7e0>, req = <urllib.request.Request object at 0x7efe6fea13c0> def open_local_file(self, req): import email.utils import mimetypes host = req.host filename = req.selector localfile = url2pathname(filename) try:
> stats = os.stat(localfile)E FileNotFoundError: [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/import.css'/usr/lib64/python3.10/urllib/request.py:1505: FileNotFoundErrorDuring handling of the above exception, another exception occurred:self = <cssutils.tests.test_cssutils.TestCSSutils object at 0x7efe6fc2fcd0> def test_parseUrl(self): "cssutils.parseUrl()" href = basetest.get_sheet_filename('import.css') # href = u'file:' + urllib.pathname2url(href) href = cssutils.helper.path2url(href) # href = 'http://seewhatever.de/sheets/import.css'
> s = cssutils.parseUrl(href, media='tv, print', title='from url')cssutils/tests/test_cssutils.py:199:_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/__init__.py:166: in func return getattr(CSSParser(), name)(*args, **kwargs)../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/parse.py:209: in parseUrl encoding, enctype, text = cssutils.util._readUrl(../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/util.py:928: in _readUrl r = fetcher(url)../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/_fetch.py:45: in _defaultFetcher log.warn('URLError, %s' % e.reason, error=e)../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/_fetch.py:39: in _defaultFetcher res = urllib.request.urlopen(request)/usr/lib64/python3.10/urllib/request.py:216: in urlopen return opener.open(url, data, timeout)/usr/lib64/python3.10/urllib/request.py:519: in open response = self._open(req, data)/usr/lib64/python3.10/urllib/request.py:536: in _open result = self._call_chain(self.handle_open, protocol, protocol +/usr/lib64/python3.10/urllib/request.py:496: in _call_chain result = func(*args)/usr/lib64/python3.10/urllib/request.py:1483: in file_open return self.open_local_file(req)_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _self = <urllib.request.FileHandler object at 0x7efe6f72d7e0>, req = <urllib.request.Request object at 0x7efe6fea13c0> def open_local_file(self, req): import email.utils import mimetypes host = req.host filename = req.selector localfile = url2pathname(filename) try: stats = os.stat(localfile) size = stats.st_size modified = email.utils.formatdate(stats.st_mtime, usegmt=True) mtype = mimetypes.guess_type(filename)[0] headers = email.message_from_string( 'Content-type: %s\nContent-length: %d\nLast-modified: %s\n' % (mtype or 'text/plain', size, modified)) if host: host, port = _splitport(host) if not host or \ (not port and _safe_gethostbyname(host) in self.get_names()): if host: origurl = 'file://' + host + filename else: origurl = 'file://' + filename return addinfourl(open(localfile, 'rb'), headers, origurl) except OSError as exp:
> raise URLError(exp)E urllib.error.URLError: <urlopen error [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/import.css'>/usr/lib64/python3.10/urllib/request.py:1522: URLError________________________________________________________________________________ TestCSSCombine.test_combine ________________________________________________________________________________self = <cssutils.tests.test_scripts_csscombine.TestCSSCombine object at 0x7efe6f7ef9a0> def test_combine(self): "scripts.csscombine()" # path, SHOULD be keyword argument! csspath = basetest.get_sheet_filename('csscombine-proxy.css')
> combined = csscombine(csspath)cssutils/tests/test_scripts_csscombine.py:17:_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _cssutils/script.py:353: in csscombine src = parser.parseFile(path, encoding=sourceencoding)_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _self = <cssutils.parse.CSSParser object at 0x7efe6f3c5720>filename = PosixPath('/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/csscombine-proxy.css'), encoding = Nonehref = 'file:/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/csscombine-proxy.css', media = None, title = Nonevalidate = None def parseFile( self, filename, encoding=None, href=None, media=None, title=None, validate=None ): """Retrieve content from `filename` and parse it. Errors may be raised (e.g. IOError). :param filename: of the CSS file to parse, if no `href` is given filename is converted to a (file:) URL and set as ``href`` of resulting stylesheet. If `href` is given it is set as ``sheet.href``. Either way ``sheet.href`` is used to resolve e.g. stylesheet imports via @import rules. :param encoding: Value ``None`` defaults to encoding detection via BOM or an @charset rule. Other values override detected encoding for the sheet at `filename` including any imported sheets. :returns: :class:`~cssutils.css.CSSStyleSheet`. """ if not href: # prepend // for file URL, urllib does not do this? # href = u'file:' + urllib.pathname2url(os.path.abspath(filename)) href = path2url(filename)
> with open(filename, 'rb') as fd:E FileNotFoundError: [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/csscombine-proxy.css'../../BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/parse.py:182: FileNotFoundError========================================================================================= XFAILURES =========================================================================================__________________________________________________________________________________ TestCSSValue.test_init ___________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb087c0> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError_________________________________________________________________________________ TestCSSValue.test_escapes _________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb098d0> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError_________________________________________________________________________________ TestCSSValue.test_cssText _________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb08e20> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError________________________________________________________________________________ TestCSSValue.test_cssText2 _________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb09e70> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError_______________________________________________________________________________ TestCSSValue.test_incomplete ________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb09270> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError______________________________________________________________________________ TestCSSValue.test_cssValueType _______________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb09720> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError________________________________________________________________________________ TestCSSValue.test_readonly _________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb094e0> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError_______________________________________________________________________________ TestCSSValue.test_reprANDstr ________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValue object at 0x7efe6fb0afb0> def setup_method(self):
> self.r = cssutils.css.CSSValue() # needed for testsE AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:16: AttributeError______________________________________________________________________________ TestCSSPrimitiveValue.test_init ______________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fb0b400> def test_init(self): "CSSPrimitiveValue.__init__()"
> v = cssutils.css.CSSPrimitiveValue('1')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:364: AttributeError__________________________________________________________________________ TestCSSPrimitiveValue.test_CSS_UNKNOWN ___________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fb0a170> def test_CSS_UNKNOWN(self): "CSSPrimitiveValue.CSS_UNKNOWN"
> v = cssutils.css.CSSPrimitiveValue('expression(false)')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:387: AttributeError________________________________________________________________ TestCSSPrimitiveValue.test_CSS_NUMBER_AND_OTHER_DIMENSIONS _________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fb0b730> def test_CSS_NUMBER_AND_OTHER_DIMENSIONS(self): "CSSPrimitiveValue.CSS_NUMBER .. CSS_DIMENSION" defs = [ ('', 'CSS_NUMBER'), ('%', 'CSS_PERCENTAGE'), ('em', 'CSS_EMS'), ('ex', 'CSS_EXS'), ('px', 'CSS_PX'), ('cm', 'CSS_CM'), ('mm', 'CSS_MM'), ('in', 'CSS_IN'), ('pt', 'CSS_PT'), ('pc', 'CSS_PC'), ('deg', 'CSS_DEG'), ('rad', 'CSS_RAD'), ('grad', 'CSS_GRAD'), ('ms', 'CSS_MS'), ('s', 'CSS_S'), ('hz', 'CSS_HZ'), ('khz', 'CSS_KHZ'), ('other_dimension', 'CSS_DIMENSION'), ] for dim, name in defs: for n in (0, 1, 1.1, -1, -1.1, -0):
> v = cssutils.css.CSSPrimitiveValue('%i%s' % (n, dim))E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:415: AttributeError______________________________________________________________________ TestCSSPrimitiveValue.test_CSS_STRING_AND_OTHER ______________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fb083d0> def test_CSS_STRING_AND_OTHER(self): "CSSPrimitiveValue.CSS_STRING .. CSS_RGBCOLOR" defs = [ ( ( '""', "''", '"some thing"', "' A\\ND '", # comma separated lists are STRINGS FOR NOW! 'a, b', '"a", "b"', ), 'CSS_STRING', ), (('url(a)', 'url("a b")', "url(' ')"), 'CSS_URI'), (('some', 'or_anth-er'), 'CSS_IDENT'), (('attr(a)', 'attr(b)'), 'CSS_ATTR'), (('counter(1)', 'counter(2)'), 'CSS_COUNTER'), (('rect(1,2,3,4)',), 'CSS_RECT'), (('rgb(1,2,3)', 'rgb(10%, 20%, 30%)', '#123', '#123456'), 'CSS_RGBCOLOR'), ( ( 'rgba(1,2,3,4)', 'rgba(10%, 20%, 30%, 40%)', ), 'CSS_RGBACOLOR', ), (('U+0', 'u+ffffff', 'u+000000-f', 'u+0-f, U+ee-ff'), 'CSS_UNICODE_RANGE'), ] for examples, name in defs: for x in examples:
> v = cssutils.css.CSSPrimitiveValue(x)E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:452: AttributeError____________________________________________________________________________ TestCSSPrimitiveValue.test_getFloat ____________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fea2bf0> def test_getFloat(self): "CSSPrimitiveValue.getFloatValue()" # NOT TESTED are float values as it seems difficult to # compare these. Maybe use decimal.Decimal?
> v = cssutils.css.CSSPrimitiveValue('1px')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:461: AttributeError____________________________________________________________________________ TestCSSPrimitiveValue.test_setFloat ____________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fea32b0> def test_setFloat(self): "CSSPrimitiveValue.setFloatValue()"
> V = cssutils.css.CSSPrimitiveValueE AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:505: AttributeError___________________________________________________________________________ TestCSSPrimitiveValue.test_getString ____________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fbfa500> def test_getString(self): "CSSPrimitiveValue.getStringValue()"
> v = cssutils.css.CSSPrimitiveValue('1px')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:656: AttributeError___________________________________________________________________________ TestCSSPrimitiveValue.test_setString ____________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fbf9d50> def test_setString(self): "CSSPrimitiveValue.setStringValue()" # CSS_STRING
> v = cssutils.css.CSSPrimitiveValue('"a"')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:684: AttributeError__________________________________________________________________________ TestCSSPrimitiveValue.test_typeRGBColor __________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fbf9270> def test_typeRGBColor(self): "RGBColor"
> v = cssutils.css.CSSPrimitiveValue('RGB(1, 5, 10)')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:820: AttributeError___________________________________________________________________________ TestCSSPrimitiveValue.test_reprANDstr ___________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSPrimitiveValue object at 0x7efe6fbfa1d0> def test_reprANDstr(self): "CSSPrimitiveValue.__repr__(), .__str__()" v = '111'
> s = cssutils.css.CSSPrimitiveValue(v)E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_cssvalue.py:843: AttributeError________________________________________________________________________________ TestCSSValueList.test_init _________________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValueList object at 0x7efe6fbfb340> def test_init(self): "CSSValueList.__init__()"
> v = cssutils.css.CSSValue(cssText='red blue')E AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:856: AttributeError_______________________________________________________________________________ TestCSSValueList.test_numbers _______________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValueList object at 0x7efe6fbf8f10> def test_numbers(self): "CSSValueList.cssText" tests = { '0 0px -0px +0px': ('0 0 0 0', 4), '1 2 3 4': (None, 4), '-1 -2 -3 -4': (None, 4), '-1 2': (None, 2), '-1px red "x"': (None, 3), 'a, b c': (None, 2), '1px1 2% 3': ('1px1 2% 3', 3), 'f(+1pX, -2, 5%) 1': ('f(1px, -2, 5%) 1', 2), '0 f()0': ('0 f() 0', 3), 'f()0': ('f() 0', 2), 'f()1%': ('f() 1%', 2), 'f()1px': ('f() 1px', 2), 'f()"str"': ('f() "str"', 2), 'f()ident': ('f() ident', 2), 'f()#123': ('f() #123', 2), 'f()url()': ('f() url()', 2), 'f()f()': ('f() f()', 2), 'url(x.gif)0 0': ('url(x.gif) 0 0', 3), 'url(x.gif)no-repeat': ('url(x.gif) no-repeat', 2), } for test in tests: exp, num = tests[test] if not exp: exp = test
> v = cssutils.css.CSSValue(cssText=test)E AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:893: AttributeError_____________________________________________________________________________ TestCSSValueList.test_reprANDstr ______________________________________________________________________________self = <cssutils.tests.test_cssvalue.TestCSSValueList object at 0x7efe6f964790> def test_reprANDstr(self): "CSSValueList.__repr__(), .__str__()" v = '1px 2px'
> s = cssutils.css.CSSValue(v)E AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_cssvalue.py:902: AttributeError__________________________________________________________________ TestProfiles.test_validateWithProfile[params3-results3] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f8909d0>, params = ('color', 'rgba(0,0,0,0)', None), results = (True, True, ['CSS Color Module Level 3']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError__________________________________________________________________ TestProfiles.test_validateWithProfile[params4-results4] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f9dc820>, params = ('color', 'rgba(0,0,0,0)', 'CSS Level 2.1'), results = (True, False, ['CSS Color Module Level 3']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError__________________________________________________________________ TestProfiles.test_validateWithProfile[params5-results5] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f9dc760>, params = ('color', 'rgba(0,0,0,0)', 'CSS Color Module Level 3')results = (True, True, ['CSS Color Module Level 3']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError__________________________________________________________________ TestProfiles.test_validateWithProfile[params6-results6] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f9dd7e0>, params = ('color', '1px', None), results = (False, False, ['CSS Color Module Level 3', 'CSS Level 2.1']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError__________________________________________________________________ TestProfiles.test_validateWithProfile[params7-results7] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f9dce80>, params = ('color', '1px', 'CSS Level 2.1')results = (False, False, ['CSS Color Module Level 3', 'CSS Level 2.1']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError__________________________________________________________________ TestProfiles.test_validateWithProfile[params8-results8] __________________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f844eb0>, params = ('color', '1px', 'CSS Color Module Level 3')results = (False, False, ['CSS Color Module Level 3', 'CSS Level 2.1']) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) def test_validateWithProfile(self, params, results): "Profiles.validate(), Profiles.validateWithProfile()" p = cssutils.profiles.Profiles() assert p.validate(*params[:2]) == results[0]
> assert p.validateWithProfile(*params) == resultsE AssertionErrorcssutils/tests/test_profiles.py:232: AssertionError_______________________________________________________________ TestProfiles.test_validateWithProfile_fonts[params0-results0] _______________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f845ed0>, params = (('CSS Fonts Module Level 3 @font-face properties',), 'font-family', ('y', '"y"'))results = (True, True, ('CSS Fonts Module Level 3 @font-face properties',)) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) @pytest.mark.xfail(reason="#37") def test_validateWithProfile_fonts(self, params, results): "Profiles.validateWithProfile()" # testing for valid values overwritten in a profile v, m, p = results expected = v, m, list(p)
> assert cssutils.profile.validateWithProfile(*params) == expectedE AssertionErrorcssutils/tests/test_profiles.py:740: AssertionError_______________________________________________________________ TestProfiles.test_validateWithProfile_fonts[params1-results1] _______________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f845ff0>, params = (('CSS Fonts Module Level 3 @font-face properties',), 'font-family', ('"y", "a"', 'a, b', 'a a'))results = (True, False, ('CSS Level 2.1',)) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) @pytest.mark.xfail(reason="#37") def test_validateWithProfile_fonts(self, params, results): "Profiles.validateWithProfile()" # testing for valid values overwritten in a profile v, m, p = results expected = v, m, list(p)
> assert cssutils.profile.validateWithProfile(*params) == expectedE AssertionErrorcssutils/tests/test_profiles.py:740: AssertionError_______________________________________________________________ TestProfiles.test_validateWithProfile_fonts[params2-results2] _______________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f846290>params = (('CSS Fonts Module Level 3 @font-face properties',), 'font-stretch', ('normal', 'wider', 'narrower', 'inherit')), results = (True, False, ('CSS Fonts Module Level 3',)) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) @pytest.mark.xfail(reason="#37") def test_validateWithProfile_fonts(self, params, results): "Profiles.validateWithProfile()" # testing for valid values overwritten in a profile v, m, p = results expected = v, m, list(p)
> assert cssutils.profile.validateWithProfile(*params) == expectedE AssertionErrorcssutils/tests/test_profiles.py:740: AssertionError_______________________________________________________________ TestProfiles.test_validateWithProfile_fonts[params3-results3] _______________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f846350>, params = (('CSS Fonts Module Level 3 @font-face properties',), 'font-style', ('inherit',))results = (True, False, ('CSS Level 2.1',)) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) @pytest.mark.xfail(reason="#37") def test_validateWithProfile_fonts(self, params, results): "Profiles.validateWithProfile()" # testing for valid values overwritten in a profile v, m, p = results expected = v, m, list(p)
> assert cssutils.profile.validateWithProfile(*params) == expectedE AssertionErrorcssutils/tests/test_profiles.py:740: AssertionError_______________________________________________________________ TestProfiles.test_validateWithProfile_fonts[params4-results4] _______________________________________________________________self = <cssutils.tests.test_profiles.TestProfiles object at 0x7efe6f846410>, params = (('CSS Fonts Module Level 3 @font-face properties',), 'font-weight', ('bolder', 'lighter', 'inherit'))results = (True, False, ('CSS Level 2.1',)) @pytest.mark.parametrize(('params', 'results'), _gen_validation_inputs()) @pytest.mark.xfail(reason="#37") def test_validateWithProfile_fonts(self, params, results): "Profiles.validateWithProfile()" # testing for valid values overwritten in a profile v, m, p = results expected = v, m, list(p)
> assert cssutils.profile.validateWithProfile(*params) == expectedE AssertionErrorcssutils/tests/test_profiles.py:740: AssertionError_____________________________________________________________________________ TestCSSVariable.test_cssValueType _____________________________________________________________________________self = <cssutils.tests.test_value.TestCSSVariable object at 0x7efe6f5a7c10> @pytest.mark.xfail(reason="not implemented") def test_cssValueType(self): "CSSValue.cssValueType .cssValueTypeString" tests = [
> (['inherit', 'INhe\\rit'], 'CSS_INHERIT', cssutils.css.CSSValue), ( [ '1', '1%', '1em', '1ex', '1px', '1cm', '1mm', '1in', '1pt', '1pc', '1deg', '1rad', '1grad', '1ms', '1s', '1hz', '1khz', '1other', '"string"', "'string'", 'url(x)', 'red', 'attr(a)', 'counter(x)', 'rect(1px, 2px, 3px, 4px)', 'rgb(0, 0, 0)', '#000', '#123456', 'rgba(0, 0, 0, 0)', 'hsl(0, 0, 0)', 'hsla(0, 0, 0, 0)', ], 'CSS_PRIMITIVE_VALUE', cssutils.css.CSSPrimitiveValue, ), ( ['1px 1px', 'red blue green x'], 'CSS_VALUE_LIST', cssutils.css.CSSValueList, ), # what is a custom value? # ([], 'CSS_CUSTOM', cssutils.css.CSSValue) ]E AttributeError: module 'cssutils.css' has no attribute 'CSSValue'. Did you mean: 'MSValue'?cssutils/tests/test_value.py:724: AttributeError______________________________________________________________________________ TestCSSPrimitiveValue.test_init ______________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a7eb0> def test_init(self): "CSSPrimitiveValue.__init__()"
> v = cssutils.css.CSSPrimitiveValue('1')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:786: AttributeError__________________________________________________________________________ TestCSSPrimitiveValue.test_CSS_UNKNOWN ___________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4c70> def test_CSS_UNKNOWN(self): "CSSPrimitiveValue.CSS_UNKNOWN"
> v = cssutils.css.CSSPrimitiveValue('expression(false)')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:809: AttributeError________________________________________________________________ TestCSSPrimitiveValue.test_CSS_NUMBER_AND_OTHER_DIMENSIONS _________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4a60> def test_CSS_NUMBER_AND_OTHER_DIMENSIONS(self): "CSSPrimitiveValue.CSS_NUMBER .. CSS_DIMENSION" defs = [ ('', 'CSS_NUMBER'), ('%', 'CSS_PERCENTAGE'), ('em', 'CSS_EMS'), ('ex', 'CSS_EXS'), ('px', 'CSS_PX'), ('cm', 'CSS_CM'), ('mm', 'CSS_MM'), ('in', 'CSS_IN'), ('pt', 'CSS_PT'), ('pc', 'CSS_PC'), ('deg', 'CSS_DEG'), ('rad', 'CSS_RAD'), ('grad', 'CSS_GRAD'), ('ms', 'CSS_MS'), ('s', 'CSS_S'), ('hz', 'CSS_HZ'), ('khz', 'CSS_KHZ'), ('other_dimension', 'CSS_DIMENSION'), ] for dim, name in defs: for n in (0, 1, 1.1, -1, -1.1, -0):
> v = cssutils.css.CSSPrimitiveValue('%i%s' % (n, dim))E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:837: AttributeError______________________________________________________________________ TestCSSPrimitiveValue.test_CSS_STRING_AND_OTHER ______________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4850> def test_CSS_STRING_AND_OTHER(self): "CSSPrimitiveValue.CSS_STRING .. CSS_RGBCOLOR" defs = [ ( ( '""', "''", '"some thing"', "' A\\ND '", # comma separated lists are STRINGS FOR NOW! 'a, b', '"a", "b"', ), 'CSS_STRING', ), (('url(a)', 'url("a b")', "url(' ')"), 'CSS_URI'), (('some', 'or_anth-er'), 'CSS_IDENT'), (('attr(a)', 'attr(b)'), 'CSS_ATTR'), (('counter(1)', 'counter(2)'), 'CSS_COUNTER'), (('rect(1,2,3,4)',), 'CSS_RECT'), (('rgb(1,2,3)', 'rgb(10%, 20%, 30%)', '#123', '#123456'), 'CSS_RGBCOLOR'), ( ( 'rgba(1,2,3,4)', 'rgba(10%, 20%, 30%, 40%)', ), 'CSS_RGBACOLOR', ), (('U+0', 'u+ffffff', 'u+000000-f', 'u+0-f, U+ee-ff'), 'CSS_UNICODE_RANGE'), ] for examples, name in defs: for x in examples:
> v = cssutils.css.CSSPrimitiveValue(x)E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:874: AttributeError____________________________________________________________________________ TestCSSPrimitiveValue.test_getFloat ____________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4640> def test_getFloat(self): "CSSPrimitiveValue.getFloatValue()" # NOT TESTED are float values as it seems difficult to # compare these. Maybe use decimal.Decimal?
> v = cssutils.css.CSSPrimitiveValue('1px')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:883: AttributeError____________________________________________________________________________ TestCSSPrimitiveValue.test_setFloat ____________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4430> def test_setFloat(self): "CSSPrimitiveValue.setFloatValue()"
> V = cssutils.css.CSSPrimitiveValueE AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:927: AttributeError___________________________________________________________________________ TestCSSPrimitiveValue.test_getString ____________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f5a4220> def test_getString(self): "CSSPrimitiveValue.getStringValue()"
> v = cssutils.css.CSSPrimitiveValue('1px')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:1077: AttributeError___________________________________________________________________________ TestCSSPrimitiveValue.test_setString ____________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f72dcf0> def test_setString(self): "CSSPrimitiveValue.setStringValue()" # CSS_STRING
> v = cssutils.css.CSSPrimitiveValue('"a"')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:1105: AttributeError__________________________________________________________________________ TestCSSPrimitiveValue.test_typeRGBColor __________________________________________________________________________self = <cssutils.tests.test_value.TestCSSPrimitiveValue object at 0x7efe6f72f130> def test_typeRGBColor(self): "RGBColor"
> v = cssutils.css.CSSPrimitiveValue('RGB(1, 5, 10)')E AttributeError: module 'cssutils.css' has no attribute 'CSSPrimitiveValue'cssutils/tests/test_value.py:1241: AttributeError____________________________________________________________________________________ TestX.test_priority ____________________________________________________________________________________self = <cssutils.tests.test_x.TestX object at 0x7efe6f8d2a40> @pytest.mark.xfail(reason="not implemented") def test_priority(self): "Property.priority" s = cssutils.parseString('a { color: red }') assert s.cssText == b'a {\n color: red\n }' assert '' == s.cssRules[0].style.getPropertyPriority('color') s = cssutils.parseString('a { color: red !important }')
> assert 'a {\n color: red !important\n }' == s.cssTextE AssertionErrorcssutils/tests/test_x.py:20: AssertionError================================================================================== short test summary info ==================================================================================XFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_init - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_escapes - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_cssText - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_cssText2 - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_incomplete - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_cssValueType - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_readonly - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValue::test_reprANDstr - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_init - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_CSS_UNKNOWN - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_CSS_NUMBER_AND_OTHER_DIMENSIONS - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_CSS_STRING_AND_OTHER - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_getFloat - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_setFloat - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_getString - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_setString - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_typeRGBColor - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSPrimitiveValue::test_reprANDstr - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValueList::test_init - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValueList::test_numbers - incompleteXFAIL cssutils/tests/test_cssvalue.py::TestCSSValueList::test_reprANDstr - incompleteXFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params3-results3] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params4-results4] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params5-results5] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params6-results6] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params7-results7] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile[params8-results8] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile_fonts[params0-results0] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile_fonts[params1-results1] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile_fonts[params2-results2] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile_fonts[params3-results3] - jaraco/cssutils#37XFAIL cssutils/tests/test_profiles.py::TestProfiles::test_validateWithProfile_fonts[params4-results4] - jaraco/cssutils#37XFAIL cssutils/tests/test_value.py::TestCSSVariable::test_cssValueType - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_init - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_CSS_UNKNOWN - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_CSS_NUMBER_AND_OTHER_DIMENSIONS - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_CSS_STRING_AND_OTHER - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_getFloat - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_setFloat - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_getString - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_setString - not implementedXFAIL cssutils/tests/test_value.py::TestCSSPrimitiveValue::test_typeRGBColor - not implementedXFAIL cssutils/tests/test_x.py::TestX::test_priority - not implementedFAILED cssutils/tests/test_cssutils.py::TestCSSutils::test_parseString - AssertionErrorFAILED cssutils/tests/test_cssutils.py::TestCSSutils::test_parseFile - FileNotFoundError: [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/i...FAILED cssutils/tests/test_cssutils.py::TestCSSutils::test_parseUrl - urllib.error.URLError: <urlopen error [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssu...FAILED cssutils/tests/test_scripts_csscombine.py::TestCSSCombine::test_combine - FileNotFoundError: [Errno 2] No such file or directory: '/home/tkloczko/rpmbuild/BUILDROOT/python-cssutils-2.11.0-2.fc37.x86_64/usr/lib/python3.10/site-packages/cssutils/tests/sheets/c...================================================================== 4 failed, 408 passed, 2 deselected, 43 xfailed in 5.23s ==================================================================
Since this issue is more general than just for jaraco/cssutils, I've moved it to jaraco/skeleton.
I believe the issue you're encountering here is you're not getting the package data (like cssutils/tests/sheets/csscombine-proxy.css). It's the same issue as jaraco/pytest-enabler#9 and jaraco/jaraco.text#5 (comment). These projects depend on setuptools_scm to infer from the git repository which files should be included in the sdist. Since you're not building from an sdist or the git repo, you'll be responsible to supply the metadata to ensure package data is included.
In the case of jaraco.text you manually copy the file. In the case of pytest-enabler, I suggested adding a MANIFEST.in that just includes everything.
Do either of those approaches work to solve this issue in general?
jaraco
changed the title
2.11.0: pytest fails in 4 units
tests failing when resources unavailable after building from Github tarball
Jun 1, 2024
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesinstaller
modulecut off from access to the public network
(pytest is executed with-m "not network"
)Here is pytest output:
List of installed modules in build env:
Please let me know if you need more details or want me to perform some diagnostics.
The text was updated successfully, but these errors were encountered: