From b06d160cb7ba5074afca4e97f338a7a22a518492 Mon Sep 17 00:00:00 2001 From: cgohlke Date: Mon, 10 Mar 2014 23:40:14 -0700 Subject: [PATCH] Fix TypeError: __class__ assignment: 'TestFlexibleMCP' object layout differs from 'UnboundSelf' --- skimage/graph/tests/test_flexible.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/skimage/graph/tests/test_flexible.py b/skimage/graph/tests/test_flexible.py index 9ae50759..8fc40d1b 100644 --- a/skimage/graph/tests/test_flexible.py +++ b/skimage/graph/tests/test_flexible.py @@ -9,7 +9,7 @@ a = np.ones((8, 8), dtype=np.float32) a[1::2] *= 2.0 -class TestFlexibleMCP(mcp.MCP_Flexible): +class FlexibleMCP(mcp.MCP_Flexible): """ Simple MCP subclass that allows the front to travel a certain distance from the seed point, and uses a constant cost factor that is independant of the cost array. @@ -38,7 +38,7 @@ class TestFlexibleMCP(mcp.MCP_Flexible): def test_flexible(): # Create MCP and do a traceback - mcp = TestFlexibleMCP(a) + mcp = FlexibleMCP(a) costs, traceback = mcp.find_costs([(0, 0)]) # Check that inner part is correct. This basically