Esempio n. 1
0
    def __call__(self, args):
        from conda_smithy.ci_skeleton import generate

        # complete configuration
        if getattr(args, "package_name") is None:
            args.package_name = "package"

        generate(
            package_name=args.package_name,
            feedstock_directory=args.feedstock_directory,
            recipe_directory=args.recipe_directory,
        )
        print(POST_SKELETON_MESSAGE.format(args=args).strip())
Esempio n. 2
0
def test_generate(tmpdir):
    generate(
        package_name="my-package",
        feedstock_directory=str(tmpdir),
        recipe_directory="myrecipe",
    )
    with open(tmpdir / "conda-forge.yml") as f:
        conda_forge_yml = f.read()
    assert conda_forge_yml == CONDA_FORGE_YML
    with open(tmpdir / "myrecipe" / "meta.yaml") as f:
        meta_yaml = f.read()
    assert meta_yaml == META_YAML
    with open(tmpdir / ".gitignore") as f:
        gitignore = f.read()
    assert gitignore == GITIGNORE