manim/tests/test_graphical_units/test_functions.py
pre-commit-ci[bot] b26137e9b6
[pre-commit.ci] pre-commit autoupdate (#2520)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/psf/black: 21.12b0 → 22.1.0](https://github.com/psf/black/compare/21.12b0...22.1.0)
- [github.com/asottile/blacken-docs: v1.12.0 → v1.12.1](https://github.com/asottile/blacken-docs/compare/v1.12.0...v1.12.1)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Darylgolden <darylgolden@gmail.com>
2022-02-09 07:55:56 +08:00

18 lines
451 B
Python

from __future__ import annotations
from manim import *
from manim.utils.testing.frames_comparison import frames_comparison
__module_test__ = "functions"
@frames_comparison
def test_FunctionGraph(scene):
graph = FunctionGraph(lambda x: 2 * np.cos(0.5 * x), x_range=[-PI, PI], color=BLUE)
scene.add(graph)
@frames_comparison
def test_ImplicitFunction(scene):
graph = ImplicitFunction(lambda x, y: x**2 + y**2 - 9)
scene.add(graph)