Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VTK
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michael Migliore
VTK
Commits
89a1622f
Commit
89a1622f
authored
2 years ago
by
Christos Tsolakis
Browse files
Options
Downloads
Patches
Plain Diff
vtkWebApplication Add test to expose memory leak
parent
63fe2ed8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Web/Core/Testing/Python/CMakeLists.txt
+1
-0
1 addition, 0 deletions
Web/Core/Testing/Python/CMakeLists.txt
Web/Core/Testing/Python/TestWebApplicationMemory.py
+33
-0
33 additions, 0 deletions
Web/Core/Testing/Python/TestWebApplicationMemory.py
with
34 additions
and
0 deletions
Web/Core/Testing/Python/CMakeLists.txt
+
1
−
0
View file @
89a1622f
...
...
@@ -5,4 +5,5 @@ vtk_add_test_python(
vtk_add_test_python
(
NO_DATA NO_VALID NO_OUTPUT
TestObjectIdMap.py
TestWebApplicationMemory.py
)
This diff is collapsed.
Click to expand it.
Web/Core/Testing/Python/TestWebApplicationMemory.py
0 → 100644
+
33
−
0
View file @
89a1622f
import
vtk
from
vtk.test
import
Testing
from
vtk.vtkWebCore
import
vtkWebApplication
class
TestWebApplicationMemory
(
Testing
.
vtkTest
):
def
testWebApplicationMemory
(
self
):
cylinder
=
vtk
.
vtkCylinderSource
()
cylinder
.
SetResolution
(
8
)
cylinderMapper
=
vtk
.
vtkPolyDataMapper
()
cylinderMapper
.
SetInputConnection
(
cylinder
.
GetOutputPort
())
cylinderActor
=
vtk
.
vtkActor
()
cylinderActor
.
SetMapper
(
cylinderMapper
)
cylinderActor
.
RotateX
(
30.0
)
cylinderActor
.
RotateY
(
-
45.0
)
ren
=
vtk
.
vtkRenderer
()
renWin
=
vtk
.
vtkRenderWindow
()
renWin
.
AddRenderer
(
ren
)
ren
.
AddActor
(
cylinderActor
)
renWin
.
SetSize
(
200
,
200
)
ren
.
ResetCamera
()
ren
.
GetActiveCamera
().
Zoom
(
1.5
)
renWin
.
Render
()
webApp
=
vtk
.
vtkWebApplication
()
# no memory leaks sould be reported when compiling with VTK_DEBUG_LEAKS
webApp
.
StillRender
(
renWin
)
if
__name__
==
"
__main__
"
:
Testing
.
main
([(
TestWebApplicationMemory
,
'
test
'
)])
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment