Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit aadecd0

Browse files
committed
update symmetric and transitive test to use behaviour 5.
1 parent 9e972ef commit aadecd0

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

lib/matplotlib/tests/test_axes.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5638,33 +5638,33 @@ def test_share_transitive():
56385638
C = fig.add_subplot(413)
56395639
D = fig.add_subplot(414)
56405640

5641-
# C -> D
5642-
share = getattr(C, "share_{}_axes".format(ax))
5643-
share(D, symmetric=False, transitive=False)
5641+
# B->C
5642+
share = getattr(B, "share_{}_axes".format(ax))
5643+
share(C, symmetric=False, transitive=False)
56445644

5645-
# A -> B
5645+
# A->D
56465646
share = getattr(A, "share_{}_axes".format(ax))
5647-
share(B, symmetric=False, transitive=False)
5647+
share(D, symmetric=False, transitive=False)
56485648

5649-
# A -> C, C -> A, C -> B, A -> D
5650-
share(C, symmetric=True, transitive=True)
5649+
# A->B, A->D, B->C then A->C, C->A, B->D, D->B, and B->A
5650+
share(B, symmetric=True, transitive=True)
56515651

56525652
# Symmetric test between A and C
56535653
assert _symmetric(A, C, ax)
56545654

5655-
# A -> B but not B -> C
5656-
assert _asymmetric(A, B, ax)
5655+
# Symmetric test between A and B
5656+
assert _symmetric(A, B, ax)
56575657

5658-
# C -> B but not B -> C
5659-
assert _asymmetric(C, B, ax)
5658+
# Symmetric test between B and D
5659+
assert _symmetric(B, D, ax)
56605660

5661-
# A -> D but not D -> D
5662-
assert _asymmetric(A, D, ax)
5661+
# B->C
5662+
assert _asymmetric(B, C, ax)
56635663

5664-
# C -> D but not D -> C
5665-
assert _asymmetric(C, D, ax)
5664+
# A->D
5665+
assert _asymmetric(A, D, ax)
56665666

5667-
assert _no_relation(B, D, ax)
5667+
assert _no_relation(C, D, ax)
56685668

56695669
plt.close(fig)
56705670

0 commit comments

Comments
 (0)