Programming exercises: Upgrade Swift to 6.2 with SwiftSyntax
#12033
+269
−210
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Upgrade Swift programming exercise infrastructure from Swift 5.2 to Swift 6.2, replacing the unmaintained swift-ast library with Apple's official swift-syntax, and modernizing all build templates to use native test output.
Checklist
General
Changes affecting Programming Exercises
Motivation and Context
The Swift programming exercise templates were significantly outdated:
LinuxMain.swiftandXCTestManifests.swift(auto-discovery available since Swift 5.4)This PR modernizes the entire Swift infrastructure to current standards.
Description
Docker Image:
ls1tum/artemis-swift-swiftlint-docker:swift5.9.2toghcr.io/ls1intum/artemis-swift-swiftlint-docker:swift6.2Package.swift:
yanagiba/swift-astwithapple/swift-syntax602.0.0Build Scripts (Aeolus & Jenkins):
swift test --parallel --xunit-output tests.xmlinstead of SwiftTestReporter--parallelflag is required due to a Swift 6 bug where--xunit-outputdoesn't work without itTest Templates:
LinuxMain.swiftandXCTestManifests.swiftstatic var allTestsfrom test filesUtilities.swiftto use SwiftSyntax'sSyntaxVisitorpattern for AST analysisXcode Templates:
Steps for Testing
Prerequisites:
Test Plain Swift Exercise
Test Swift Exercise with Static Code Analysis
Exam Mode Testing
Prerequisites:
Testserver States
You can manage test servers using Helios. Check environment statuses in the environment list. To deploy to a test server, go to the CI/CD page, find your PR or branch, and trigger the deployment.
Review Progress
Performance Review
Code Review
Manual Tests
Exam Mode Test
Test Coverage
No code changes detected - test coverage not required for this PR.
Last updated: 2026-01-28 15:18:00 UTC