Skip to content

Remove end to end tests #181

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 0 additions & 25 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,30 +1,5 @@
from manim import config
import pytest
import numpy as np
import os
import sys
import logging


def pytest_addoption(parser):
parser.addoption("--skip_end_to_end", action="store_true", default=False,
help="Will skip all the end-to-end tests. Useful when ffmpeg is not installed, e.g. on Windows jobs.")


def pytest_configure(config):
config.addinivalue_line(
"markers", "skip_end_to_end: mark test as end_to_end test")


def pytest_collection_modifyitems(config, items):
if not config.getoption("--skip_end_to_end"):
return
else:
skip_end_to_end = pytest.mark.skip(
reason="End to end test skipped due to --skip_end_to_end flag")
for item in items:
if "skip_end_to_end" in item.keywords:
item.add_marker(skip_end_to_end)


@pytest.fixture(scope="module")
Expand Down
14 changes: 0 additions & 14 deletions tests/manim.cfg

This file was deleted.

16 changes: 7 additions & 9 deletions tests/test_cli/test_cli.py → tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,31 +15,29 @@ def capture(command):

def test_help(python_version):
command = [python_version, "-m", "manim", "--help"]
out, err, exitcode = capture(command)
_, err, exitcode = capture(command)
assert exitcode == 0, f"Manim has been installed incorrectly. Please refer to the troubleshooting section on the wiki. Error:\n{err}"


@pytest.mark.skip_end_to_end
def test_basicScene(python_version):
""" Simulate SquareToCircle. The cache will be saved in tests_caches/media_temp (temporary directory). This is mainly intended to test the partial-movies process. """
path_basic_scene = os.path.join("tests_data", "basic_scenes.py")
path_output = os.path.join("tests_cache", "media_temp")
path_basic_scene = os.path.join("tests", "tests_data", "basic_scenes.py")
path_output = os.path.join("tests", "tests_cache", "media_temp")
command = [python_version, "-m", "manim", path_basic_scene,
"SquareToCircle", "-l", "--media_dir", path_output]
out, err, exitcode = capture(command)
_, err, exitcode = capture(command)
assert exitcode == 0, err
assert os.path.exists(os.path.join(
path_output, "videos", "basic_scenes", "480p15", "SquareToCircle.mp4")), err
rmtree(path_output)

@pytest.mark.skip_end_to_end
def test_WriteStuff(python_version):
"""This is mainly intended to test the caching process of the tex objects"""
path_basic_scene = os.path.join("tests_data", "basic_scenes.py")
path_output = os.path.join("tests_cache", "media_temp")
path_basic_scene = os.path.join("tests", "tests_data", "basic_scenes.py")
path_output = os.path.join("tests", "tests_cache", "media_temp")
command = [python_version, "-m", "manim", path_basic_scene,
"WriteStuff", "-l", "--media_dir", path_output]
out, err, exitcode = capture(command)
_, err, exitcode = capture(command)
assert exitcode == 0, err
assert os.path.exists(os.path.join(
path_output, "videos", "basic_scenes", "480p15", "WriteStuff.mp4")), err
Expand Down
6 changes: 0 additions & 6 deletions tests/test_cli/manim.cfg

This file was deleted.

93 changes: 0 additions & 93 deletions tests/test_creation.py

This file was deleted.

110 changes: 0 additions & 110 deletions tests/test_geometry.py

This file was deleted.

25 changes: 0 additions & 25 deletions tests/test_graph.py

This file was deleted.

2 changes: 0 additions & 2 deletions tests/test_imports.py

This file was deleted.

Loading