From b51d9e332ac501634d20346a17a3bba865d4e7fd Mon Sep 17 00:00:00 2001 From: Eduardo Blancas Date: Fri, 30 Dec 2022 19:06:20 -0600 Subject: [PATCH] cleaning up tests --- src/tests/test_magic.py | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/src/tests/test_magic.py b/src/tests/test_magic.py index 30afe32f1..4dcc790e0 100644 --- a/src/tests/test_magic.py +++ b/src/tests/test_magic.py @@ -186,27 +186,20 @@ def test_displaylimit_disabled(ip, value): ip.run_line_magic("config", "SqlMagic.autolimit = None") ip.run_line_magic("config", f"SqlMagic.displaylimit = {value}") - result = runsql( - ip, - "SELECT * FROM (VALUES ('apple'), ('banana'), ('cherry')) " - "AS Result ORDER BY 1;", - ) - assert "apple" in result._repr_html_() - assert "banana" in result._repr_html_() - assert "cherry" in result._repr_html_() + result = runsql(ip, "SELECT * FROM author;") + + assert "Brecht" in result._repr_html_() + assert "Shakespeare" in result._repr_html_() def test_displaylimit(ip): ip.run_line_magic("config", "SqlMagic.autolimit = None") ip.run_line_magic("config", "SqlMagic.displaylimit = 1") - result = runsql( - ip, - "SELECT * FROM (VALUES ('apple'), ('banana'), ('cherry')) " - "AS Result ORDER BY 1;", - ) - assert "apple" in result._repr_html_() - assert "cherry" not in result._repr_html_() + result = runsql(ip, "SELECT * FROM author ORDER BY first_name;") + + assert "Brecht" in result._repr_html_() + assert "Shakespeare" not in result._repr_html_() def test_column_local_vars(ip):