Skip to content
This repository was archived by the owner on Sep 2, 2022. It is now read-only.

8265073: XML transformation and indentation when using xml:space #89

Closed
wants to merge 2 commits into from

Conversation

JoeWang-Java
Copy link
Member

@JoeWang-Java JoeWang-Java commented Jun 17, 2021

The issue was that the attribute was processed before the variable was set (e.g. m_preserveSpaces.push). Reversing the order fixed it.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8265073: XML transformation and indentation when using xml:space

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk17 pull/89/head:pull/89
$ git checkout pull/89

Update a local copy of the PR:
$ git checkout pull/89
$ git pull https://git.openjdk.java.net/jdk17 pull/89/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 89

View PR using the GUI difftool:
$ git pr show -t 89

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk17/pull/89.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Jun 17, 2021

👋 Welcome back joehw! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr Pull request is ready for review label Jun 17, 2021
@openjdk
Copy link

openjdk bot commented Jun 17, 2021

@JoeWang-Java The following label will be automatically applied to this pull request:

  • core-libs

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the core-libs core-libs-dev@openjdk.java.net label Jun 17, 2021
@mlbridge
Copy link

mlbridge bot commented Jun 17, 2021

Webrevs

Copy link
Member

@naotoj naotoj left a comment

Choose a reason for hiding this comment

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

Looks good overall. Some minor comments in the test.

* Bug: 8265073
* source and expected output
*/
@DataProvider(name = "preserveSpace")
Copy link
Member

Choose a reason for hiding this comment

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

You would not need the name, since the default name is the DataProvider method name.

* source and expected output
*/
@DataProvider(name = "preserveSpace")
public Object[][] preserveSpace() throws Exception {
Copy link
Member

Choose a reason for hiding this comment

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

throws Exception may be eliminated.

* within the relevant elements.
* @param xml the source
* @param expected the expected result
* @throws Exception if the test fails
Copy link
Member

Choose a reason for hiding this comment

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

Exception is thrown from transform method. So the description is not wrong, but it may imply the objective of this test failed, i.e. the result of assertEquals().

Copy link
Contributor

@LanceAndersen LanceAndersen left a comment

Choose a reason for hiding this comment

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

Looks fine. I still add the DataProvider name out of habit myself even though it is always the same as the method names for me (some habits are hard to break)

@openjdk
Copy link

openjdk bot commented Jun 17, 2021

@JoeWang-Java This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8265073: XML transformation and indentation when using xml:space

Reviewed-by: naoto, lancea, iris

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 14 new commits pushed to the master branch:

  • 9130b8a: 8268371: C2: assert(_gvn.type(obj)->higher_equal(tjp)) failed: cast_up is no longer needed
  • 8545269: 8268676: assert(!ik->is_interface() && !ik->has_subklass()) failed: inconsistent klass hierarchy
  • c98d508: 8268265: MutableSpaceUsedHelper::take_sample() hits assert(left >= right) failed: avoid overflow
  • b66001a: 8268971: ProblemList tools/jpackage/windows/WinInstallerIconTest.java on win-x64
  • 0011b52: 8264843: Javac crashes with NullPointerException when finding unencoded XML in
     tag
  • 2047da7: 8265297: javax/net/ssl/SSLSession/TestEnabledProtocols.java failed with "RuntimeException: java.net.SocketException: Connection reset"
  • 091bc4a: 8268353: Test libsvml.so is and is not present in jdk image
  • 69d01b6: 8249899: jdk/javadoc/tool/InlineTagsWithBraces.java uses @ignore w/o bug-id
  • 7d7bdbe: 8268776: Test ADatagramSocket.java missing /othervm from @run tag
  • 344e3ed: 8268080: java/util/concurrent/forkjoin/AsyncShutdownNow.java fails with java.util.concurrent.RejectedExecutionException
  • ... and 4 more: https://git.openjdk.java.net/jdk17/compare/f0f2178876813cca070db01ce37ea7a04b712923...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Jun 17, 2021
@JoeWang-Java
Copy link
Member Author

Thanks Lance. Indeed, me too. So this is the first without the name parameter :-)

Copy link
Member

@naotoj naotoj left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks for the fix!

@JoeWang-Java
Copy link
Member Author

Thanks Iris.

@JoeWang-Java
Copy link
Member Author

/integrate

@openjdk
Copy link

openjdk bot commented Jun 18, 2021

Going to push as commit 7e03cf2.
Since your change was applied there have been 32 commits pushed to the master branch:

  • 60389ee: 8269025: jsig/Testjsig.java doesn't check exit code
  • dab00ee: 8266518: Refactor and expand scatter/gather tests
  • f9c8c1c: 8268903: JFR: RecordingStream::dump is missing @SInCE
  • d8a0582: 8265369: [macos-aarch64] java/net/MulticastSocket/Promiscuous.java failed with "SocketException: Cannot allocate memory"
  • 21abcc4: 8268564: mark hotspot serviceability/attach tests which ignore external VM flags
  • f83c6b8: 8268531: mark SDTProbesGNULinuxTest as ignoring external VM flags
  • 8366c69: 8268541: mark hotspot serviceability/sa tests which ignore external VM flags
  • 5b19898: 8268563: mark hotspot serviceability/jvmti tests which ignore external VM flags
  • 2f65d40: 8268599: mark hotspot runtime/sealedClasses tests which ignore external VM flags
  • 3e1dc0a: 8268598: mark hotspot runtime/stringtable tests which ignore external VM flags
  • ... and 22 more: https://git.openjdk.java.net/jdk17/compare/f0f2178876813cca070db01ce37ea7a04b712923...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Jun 18, 2021
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Jun 18, 2021
@openjdk
Copy link

openjdk bot commented Jun 18, 2021

@JoeWang-Java Pushed as commit 7e03cf2.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@JoeWang-Java JoeWang-Java deleted the JDK-8265073 branch June 19, 2021 04:48
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
core-libs core-libs-dev@openjdk.java.net integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

4 participants