Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Xdmf
Xdmf
Commits
0a994266
Commit
0a994266
authored
Jun 13, 2011
by
panneton
Committed by
Brian Panneton
Jun 13, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ENH: Added Java Test to make sure the Garbage Collector works correctly
parent
6fa7fe7b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
0 deletions
+19
-0
tests/Java/CMakeLists.txt
tests/Java/CMakeLists.txt
+2
-0
tests/Java/TestXdmfGC.java
tests/Java/TestXdmfGC.java
+17
-0
No files found.
tests/Java/CMakeLists.txt
View file @
0a994266
...
...
@@ -20,6 +20,7 @@ ADD_TEST_JAVA_LDPATH("")
# ------------------------
ADD_TEST_JAVA
(
TestXdmfJava
)
ADD_TEST_JAVA
(
TestXdmfEquals
)
ADD_TEST_JAVA
(
TestXdmfGC
)
# Add any java cleanup here:
# Note: We don't want to use a foreach loop to test the files incase we
...
...
@@ -30,6 +31,7 @@ CLEAN_TEST_JAVA(TestXdmfJava
outputJavaTest.xmf
)
CLEAN_TEST_JAVA
(
TestXdmfEquals
)
CLEAN_TEST_JAVA
(
TestXdmfGC outputXdmfGC.xmf
)
# Add a custom target for all java tests
# Note: ${TARGETS} is set in ADD_TEST_JAVA
...
...
tests/Java/TestXdmfGC.java
0 → 100644
View file @
0a994266
import
mil.army.arl.xdmf.*
;
public
class
TestXdmfGC
{
public
static
void
main
(
String
argv
[])
{
System
.
out
.
println
(
"Hello Java World (Garbage Collector)"
);
for
(
int
i
=
0
;
i
<
10
;
i
++)
{
System
.
gc
();
XdmfWriter
w
=
XdmfWriter
.
New
(
"outputXdmfGC"
);
XdmfDomain
d
=
XdmfDomain
.
New
();
d
.
accept
(
w
);
}
System
.
out
.
println
(
"Done"
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment