def test_build_script(self): fLOG( __file__, self._testMethodName, OutputPrint=__name__ == "__main__") if sys.platform.startswith("win"): sc = get_build_script("pyquickhelper") # fLOG(sc) assert "c:\\Python34_x64vir%virtual_env_suffix%\\install" in sc lines = sc.split("\n") for line in lines: if "__" in line and _default_nofolder not in line: raise Exception("issue with __ in:\n" + line) scc = get_script_command( "unittest", "pyquickhelper", requirements=[]) assert "setup.py" in scc assert "__" not in scc sccc = get_extra_script_command( "local_pypi", "pyquickhelper", port=8067, requirements=[]) assert "python" in sccc if "__" in sccc: raise Exception(sccc) else: # not yet implemented for this platform return
def test_build_script_all(self): fLOG( __file__, self._testMethodName, OutputPrint=__name__ == "__main__") project_var_name = "pyquickhelper" requirements = None port = 8067 if sys.platform.startswith("win"): for c in ("build_script", "clean_space", "write_version", "clean_pyd", "build_sphinx", "unittests", "unittests_LONG", "unittests_SKIP", "copy27", "test_local_pypi", "setup_hook", "unittests_GUI"): sc = get_script_command( c, project_var_name, requirements=requirements, port=port) assert len(sc) > 0 if "__" in sc: if sys.version_info[0] == 2: continue raise Exception("{0}\n----------\n{1}".format(c, sc)) unit_test_folder = os.path.abspath( os.path.join(os.path.dirname(__file__), "..")) for c in {"notebook", "publish", "publish_doc", "local_pypi", "setupdep", "copy_dist", "any_setup_command", "build_dist"}: sc = get_extra_script_command( c, project_var_name, requirements=requirements, port=port, unit_test_folder=unit_test_folder) assert len(sc) > 0 if "__" in sc: if sys.version_info[0] == 2: continue raise Exception( c + "\n\n" + "\n__##__##__##__\n".join(sc.split("__"))) if c == "run27": if sys.version_info[0] == 2: continue if "nosetest" not in sc: raise Exception(sc) else: # not yet implemented for this platform return
def test_build_script_all(self): fLOG( __file__, self._testMethodName, OutputPrint=__name__ == "__main__") project_var_name = "pyquickhelper" requirements = None port = 8067 if sys.platform.startswith("win"): for c in {"build_script", "clean_space", "write_version", "clean_pyd", "build_sphinx", "unittests", "unittests_LONG", "unittests_SKIP", "copy27", "test_local_pypi", "setup_hook"}: sc = get_script_command( c, project_var_name, requirements=requirements, port=port) assert len(sc) > 0 assert "__" not in sc for c in {"notebook", "publish", "publish_doc", "local_pypi", "run27", "build27", "setupdep", "copy_dist", "any_setup_command", "build_dist"}: sc = get_extra_script_command( c, project_var_name, requirements=requirements, port=port) assert len(sc) > 0 assert "__" not in sc if c == "run27": if "nosetest" not in sc: raise Exception(sc) else: # not yet implemented for this platform return