Skip to content

Commit

Permalink
8314320: Mark runtime/CommandLine/ tests as flagless
Browse files Browse the repository at this point in the history
Reviewed-by: dholmes
  • Loading branch information
lmesnik committed Aug 18, 2023
1 parent fbe28ee commit f481477
Show file tree
Hide file tree
Showing 23 changed files with 55 additions and 25 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8006298
* @summary Setting an invalid value for a bool argument should result in a useful error message
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
* @test
* @bug 7167142
* @summary Warn if unused .hotspot_compiler file is present
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test ConfigFileParsing
* @bug 7158804
* @summary Improve config file parsing
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 7167142
* @summary Warn if unused .hotspot_rc file is present
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 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
Expand All @@ -25,6 +25,7 @@
* @test DoubleFlagWithIntegerValue
* @bug 8178364
* @summary Command-line flags of type double should accept integer values
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8006298
* @summary Setting a flag to an invalid value should print a useful error message
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand Down Expand Up @@ -29,7 +29,7 @@
* @test
* @bug 8129855
* @summary -XX:+IgnoreUnrecognizedVMOptions should work according to the spec from JDK-8129855
*
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8006298
* @summary Using a bool (+/-) prefix on non-bool flag should result in a useful error message
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 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
Expand Down Expand Up @@ -28,6 +28,7 @@
* @modules java.base/jdk.internal.misc
* @library /test/lib
* @requires vm.debug == true
* @requires vm.flagless
* @run driver ObsoleteFlagErrorMessage
*/

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand All @@ -26,6 +26,7 @@
* @summary Verify jcmd error message for out-of-range value and for
* value which is not allowed by constraint. Also check that
* jcmd does not print an error message to the target process output.
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2022, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand Down Expand Up @@ -27,6 +27,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (1 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -38,6 +39,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (2 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -49,6 +51,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (3 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -60,6 +63,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (4 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -71,6 +75,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (5 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -82,6 +87,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (6 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -93,6 +99,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (7 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -104,6 +111,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (8 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -115,6 +123,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (9 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand All @@ -126,6 +135,7 @@
* @test
* @bug 8205633
* @summary Test VM Options with ranges (10 of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand All @@ -24,6 +24,7 @@
/*
* @test
* @summary Test writeable VM Options with ranges.
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* jdk.attach/sun.tools.attach
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2018, 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
Expand All @@ -24,12 +24,13 @@
echo "// --- start auto-generated"
echo "// the following portion is auto-generated by $0. Do not edit manually."

for i in {1..10}; do
for i in {1..10}; do
cat <<EOF
/*
* @test
* @bug 8205633
* @summary Test VM Options with ranges ($i of 10)
* @requires vm.flagless
* @library /test/lib /runtime/CommandLine/OptionsValidation/common
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
3 changes: 2 additions & 1 deletion test/hotspot/jtreg/runtime/CommandLine/TestHexArguments.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 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
Expand All @@ -26,6 +26,7 @@
* @bug 8042885
* @summary Make sure there is no error using hexadecimal format in vm options
* @author Yumin Qi
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8129786
* @summary Verify that JVM correctly processes very long unrecognized VM option
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* @modules java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 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
Expand Down Expand Up @@ -28,6 +28,7 @@
* @test TestNullTerminatedFlags
* @bug 6522873
* @summary Test that the VM don't allow random junk characters at the end of valid command line flags.
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down Expand Up @@ -64,4 +65,3 @@ public static void main(String args[]) throws Exception{
}
}
}

3 changes: 2 additions & 1 deletion test/hotspot/jtreg/runtime/CommandLine/TestVMOptions.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8060256
* @summary Test various command line options
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8048933
* @summary -Xlog:exceptions=info output should have the exception message - useful for ClassNotFoundExceptions especially
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 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
Expand All @@ -25,6 +25,7 @@
* @test
* @bug 8006298 8204055
* @summary Using an unrecognized VM option should print the name of the option
* @requires vm.flagless
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.management
Expand Down
3 changes: 2 additions & 1 deletion test/hotspot/jtreg/runtime/CommandLine/VMAliasOptions.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand Down Expand Up @@ -29,6 +29,7 @@
* @test
* @bug 8061611
* @summary Test that various alias options correctly set the target options. See aliased_jvm_flags in arguments.cpp.
* @requires vm.flagless
* @modules java.base/jdk.internal.misc
* @library /test/lib
* @run driver VMAliasOptions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2022, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 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
Expand Down Expand Up @@ -34,6 +34,7 @@
* @test
* @bug 8066821
* @summary Test that various options are deprecated. See deprecated_jvm_flags in arguments.cpp.
* @requires vm.flagless
* @modules java.base/jdk.internal.misc
* @library /test/lib
* @build jdk.test.whitebox.WhiteBox
Expand Down

3 comments on commit f481477

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@GoeLin
Copy link
Member

@GoeLin GoeLin commented on f481477 Dec 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jdk21u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on f481477 Dec 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@GoeLin the backport was successfully created on the branch backport-GoeLin-f4814771 in my personal fork of openjdk/jdk21u-dev. To create a pull request with this backport targeting openjdk/jdk21u-dev:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit f4814771 from the openjdk/jdk repository.

The commit being backported was authored by Leonid Mesnik on 18 Aug 2023 and was reviewed by David Holmes.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk21u-dev:

$ git fetch https://github.com/openjdk-bots/jdk21u-dev.git backport-GoeLin-f4814771:backport-GoeLin-f4814771
$ git checkout backport-GoeLin-f4814771
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk21u-dev.git backport-GoeLin-f4814771

Please sign in to comment.