@@ -174,7 +174,7 @@ def test_surface3D(self):
174
174
175
175
with plt .rc_context (rc = RC_PARAMS ):
176
176
fig = plt .figure ()
177
- ax = fig . gca (projection = "3d" )
177
+ ax = plt . axes (projection = "3d" )
178
178
179
179
# Plot the surface.
180
180
surf = ax .plot_surface (
@@ -217,7 +217,7 @@ def test_trisurface3D(self):
217
217
218
218
with plt .rc_context (rc = RC_PARAMS ):
219
219
fig = plt .figure ()
220
- ax = fig . gca (projection = "3d" )
220
+ ax = plt . axes (projection = "3d" )
221
221
222
222
ax .plot_trisurf (x , y , z , linewidth = 0.2 , antialiased = True )
223
223
with pytest .warns (Warning ):
@@ -244,7 +244,7 @@ def test_polygon3D(self):
244
244
245
245
with plt .rc_context (rc = RC_PARAMS ):
246
246
fig = plt .figure ()
247
- ax = fig . gca (projection = "3d" )
247
+ ax = plt . axes (projection = "3d" )
248
248
249
249
def cc (arg ):
250
250
"""
@@ -302,7 +302,7 @@ def test_bar3D(self):
302
302
def test_quiver3D (self ):
303
303
with plt .rc_context (rc = RC_PARAMS ):
304
304
fig = plt .figure ()
305
- ax = fig . gca (projection = "3d" )
305
+ ax = plt . axes (projection = "3d" )
306
306
307
307
# Make the grid
308
308
x , y , z = np .meshgrid (
@@ -328,8 +328,7 @@ def test_quiver3D(self):
328
328
329
329
def test_2D_in_3D (self ):
330
330
with plt .rc_context (rc = RC_PARAMS ):
331
- fig = plt .figure ()
332
- ax = fig .gca (projection = "3d" )
331
+ ax = plt .axes (projection = "3d" )
333
332
334
333
# Plot a sin curve using the x and y axes.
335
334
x = np .linspace (0 , 1 , 100 )
0 commit comments