Files
pyscript/pyscriptjs/__mocks__/fileMock.js
Jeff Glass 687b93d148 Import PyScript Version into Python Runtime (#958)
* Import current version as PyScript.__version__ and PyScript.version_info

* Add integration, python unit tests
 
* Mock pyscript.py with __mocks__/pyscript.js to make jest tests happy
2022-11-18 11:49:45 -06:00

17 lines
515 B
JavaScript

/**
* this file mocks python files that are not explicitly
* matched by a regex in jest.config.js, since importing of
* `.py` files isn't usually supported inside JS/TS files.
*
* This is needed since the imported object is further
* passed to a function which only accepts a string.
*
* The mocked contents of the `.py` file will be "", e.g.
* nothing.
*/
console.warn(`.py files that are not explicitly mocked in \
jest.config.js and /__mocks__/ are mocked as empty strings`);
module.exports = "";