# Path: pyLIMA/microlcaustics.py
# def find_2_lenses_caustics_and_critical_curves(separation, mass_ratio, resolution=1000):
# def sort_2lenses_resonant_caustic(caustic_points, critical_curves_points):
# def sort_2lenses_close_caustics(caustic_points, critical_curves_points):
# def sort_2lenses_wide_caustics(caustic_points, critical_curves_points):
# def compute_2_lenses_caustics_points(separation, mass_ratio, resolution=1000):
# def find_area_of_interest_around_caustics(caustics, secure_factor=0.1):
# def find_2_lenses_caustic_regime(separation, mass_ratio):
# def change_source_trajectory_center_to_central_caustics_center(separation, mass_ratio):
# def change_source_trajectory_center_to_planetary_caustics_center(separation, mass_ratio):
# def dx(function, x, args):
# def newtons_method(function, jaco, x0, args=None, e=10 ** -10):
# def foo(x, pp1, pp2, pp3, pp4, pp5):
# def foo2(X, pp1, pp2, pp3, pp4, pp5):
# def jaco(x, pp1, pp2, pp3, pp4, pp5):
# def hessian(x, pp1, pp2, pp3, pp4, pp5):
# def Jacobian(zi, mtot, deltam, z1):
# def find_slices(slice_1, slice_2, points):


import numpy as np
import unittest.mock
import pytest
from pyLIMA import microlcaustics
        if solution[index] is not None:

            assert caustic is not None

        else:

            assert caustic is None

    for index, critical_curve in enumerate(critical_curves):

        if solution[index] is not None:

            assert critical_curve is not None

        else:

            assert critical_curve is None

    assert len(caustics[0]) == 2000
    assert len(critical_curves[0]) == 2000
    assert len(caustics[1]) == 1000
    assert len(critical_curves[1]) == 1000
    assert len(caustics[2]) == 1000
    assert len(critical_curves[2]) == 1000


def test_sort_2lenses_resonant_caustic():
    separation = 1
    mass_ratio = 1


# Path: pyLIMA/microlcaustics.py
# def find_2_lenses_caustics_and_critical_curves(separation, mass_ratio, resolution=1000):
# def sort_2lenses_resonant_caustic(caustic_points, critical_curves_points):
# def sort_2lenses_close_caustics(caustic_points, critical_curves_points):
# def sort_2lenses_wide_caustics(caustic_points, critical_curves_points):
# def compute_2_lenses_caustics_points(separation, mass_ratio, resolution=1000):
# def find_area_of_interest_around_caustics(caustics, secure_factor=0.1):
# def find_2_lenses_caustic_regime(separation, mass_ratio):
# def change_source_trajectory_center_to_central_caustics_center(separation, mass_ratio):
# def change_source_trajectory_center_to_planetary_caustics_center(separation, mass_ratio):
# def dx(function, x, args):
# def newtons_method(function, jaco, x0, args=None, e=10 ** -10):
# def foo(x, pp1, pp2, pp3, pp4, pp5):
# def foo2(X, pp1, pp2, pp3, pp4, pp5):
# def jaco(x, pp1, pp2, pp3, pp4, pp5):
# def hessian(x, pp1, pp2, pp3, pp4, pp5):
# def Jacobian(zi, mtot, deltam, z1):
# def find_slices(slice_1, slice_2, points):


# Path: pyLIMA/test/test_microlcaustics.py
import numpy as np
import unittest.mock
import pytest
from pyLIMA import microlcaustics

        if solution[index] is not None:

            assert caustic is not None

        else:

            assert caustic is None

    for index, critical_curve in enumerate(critical_curves):

        if solution[index] is not None:

            assert critical_curve is not None

        else:

            assert critical_curve is None

    assert len(caustics[0]) == 2000
    assert len(critical_curves[0]) == 2000
    assert len(caustics[1]) == 1000
    assert len(critical_curves[1]) == 1000
    assert len(caustics[2]) == 1000
    assert len(critical_curves[2]) == 1000


def test_sort_2lenses_resonant_caustic():
    separation = 1
    mass_ratio = 1


    caustics, critical_curves = microlcaustics.compute_2_lenses_caustics_points(separation, mass_ratio,