From ff2348e71af6705dfa3220d823ce0285e95b127f Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Wed, 31 Jul 2019 09:16:46 +0300 Subject: [PATCH] Added failing tests --- tests/test_m2m.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tests/test_m2m.py b/tests/test_m2m.py index e7d6e30..c7e593d 100644 --- a/tests/test_m2m.py +++ b/tests/test_m2m.py @@ -41,3 +41,20 @@ def test_insert_m2m_list(fresh_db): other_column="id", ), ] == dogs_humans.foreign_keys + + +def test_m2m_explicit_argument(fresh_db): + # .m2m("humans", ..., m2m_table="relationships") + assert False + + +def test_uses_existing_m2m_table_if_exists(fresh_db): + # Code should look for an existing toble with fks to both tables + # and use that if it exists. + assert False + + +def test_requires_explicit_m2m_table_if_multiple_options(fresh_db): + # If the code scans for m2m tables and finds more than one candidate + # it should require that the m2m_table=x argument is used + assert False