/* * Copyright (c) 2012, 2023, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ /* * @test * @bug 7112427 8012295 8025633 8026567 8061305 8081854 8150130 8162363 * 8167967 8172528 8175200 8178830 8182257 8186332 8182765 8025091 * 8203791 8184205 8249633 8261976 * @summary Test of the JavaFX doclet features. * @library ../../lib * @modules jdk.javadoc/jdk.javadoc.internal.tool * @build javadoc.tester.* * @run main TestJavaFX */ import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import javadoc.tester.JavadocTester; public class TestJavaFX extends JavadocTester { public static void main(String... args) throws Exception { var tester = new TestJavaFX(); tester.setAutomaticCheckAccessibility(false); tester.setAutomaticCheckLinks(false); tester.runTests(); } @Test public void test1() { javadoc("-d", "out1", "-sourcepath", testSrc, "-javafx", "--disable-javafx-strict-checks", "-Xdoclint:all,-missing", "-package", "pkg1"); checkExit(Exit.OK); checkOutput("pkg1/C.html", true, """
rate
property.rate
property.final C.DoubleProperty
Timeline
is expected to
be played.paused
property.paused
property.paused
property.Timeline
is expected to
be played. This is the second line.rate
property.Timeline
is expected to
be played. This is the second line.value
- the value for the rate
propertyrate
property.Timeline
is expected to
be played. This is the second line.rate
propertyfinal C.BooleanProperty
final C.DoubleProperty
C.BooleanProperty
C.DoubleProperty
paused
property.paused, rate
""");
checkOutput("pkg1/D.html", false, "shouldNotAppear");
}
/*
* Test with -javafx option enabled, to ensure property getters and setters
* are treated correctly.
*/
@Test
public void test2() {
javadoc("-d", "out2a",
"-sourcepath", testSrc,
"-javafx",
"--disable-javafx-strict-checks",
"--no-platform-links",
"-Xdoclint:all,-missing",
"-package",
"pkg2");
checkExit(Exit.OK);
checkOutput("pkg2/Test.html", true,
"""
<T> java.lang.Object
alphaProperty(java.util.List<T> foo)\
java.lang.Object
final java.util.List<java.util.Set&\
lt;? super java.lang.Object>>
final java.util.List<java.lang.Strin\
g>