From bb5cee6fd6dae6e216c5fea49aef9a8713ab7f98 Mon Sep 17 00:00:00 2001 From: John Siirola Date: Wed, 29 Nov 2023 13:38:30 -0700 Subject: [PATCH] NFC: apply black --- pyomo/repn/tests/ampl/test_nlv2.py | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/pyomo/repn/tests/ampl/test_nlv2.py b/pyomo/repn/tests/ampl/test_nlv2.py index 4bdbef4e31e..32274f26a0c 100644 --- a/pyomo/repn/tests/ampl/test_nlv2.py +++ b/pyomo/repn/tests/ampl/test_nlv2.py @@ -1565,18 +1565,17 @@ def test_presolve_named_expressions(self): m.eq = pyo.Constraint(pyo.Integers) m.eq[1] = m.x[1] == 7 m.eq[2] = m.x[3] == 0.1 * m.subexpr[1] * m.x[2] - m.obj = pyo.Objective(expr=m.x[1]**2 + m.x[2]**2 + m.x[3]**3) + m.obj = pyo.Objective(expr=m.x[1] ** 2 + m.x[2] ** 2 + m.x[3] ** 3) OUT = io.StringIO() with LoggingIntercept() as LOG: - nlinfo = nl_writer.NLWriter().write(m, OUT, symbolic_solver_labels=True, linear_presolve=True) + nlinfo = nl_writer.NLWriter().write( + m, OUT, symbolic_solver_labels=True, linear_presolve=True + ) self.assertEqual(LOG.getvalue(), "") self.assertEqual( - nlinfo.eliminated_vars, - [ - (m.x[1], nl_writer.AMPLRepn(7, {}, None)), - ], + nlinfo.eliminated_vars, [(m.x[1], nl_writer.AMPLRepn(7, {}, None))] ) self.assertEqual( @@ -1634,7 +1633,6 @@ def test_presolve_named_expressions(self): ) ) - def test_scaling(self): m = pyo.ConcreteModel() m.x = pyo.Var(initialize=0)