@@ -275,16 +275,28 @@ jobs:
275275 set -e
276276
277277 if [[ "${{ needs.setup-and-changelog.outputs.environment }}" == "test" ]]; then
278- # Test run - use current version with pre-release suffix (no actual version bump)
278+ # Test run - calculate next version but don't commit it
279279 CURRENT_VERSION=$(poetry version -s)
280- TIMESTAMP=$(date +"%m%d%H%M")
281- TEST_VERSION="${CURRENT_VERSION}rc${TIMESTAMP}"
280+
281+ # Calculate what the next version would be based on release type
282+ RELEASE_TYPE="${{ needs.setup-and-changelog.outputs.release_type }}"
283+
284+ # Use poetry to calculate next version (temporarily)
285+ poetry version "$RELEASE_TYPE"
286+ NEXT_VERSION=$(poetry version -s)
287+
288+ # Reset to original version (don't commit the bump)
289+ poetry version "$CURRENT_VERSION"
290+
291+ # Create test version with timestamp in PST
292+ TIMESTAMP=$(TZ='America/Los_Angeles' date +"%m%d%H%M")
293+ TEST_VERSION="${NEXT_VERSION}rc${TIMESTAMP}"
282294
283295 # Temporarily update pyproject.toml for the build only
284296 poetry version "$TEST_VERSION"
285297
286298 echo "version=$TEST_VERSION" >> $GITHUB_OUTPUT
287- echo "Test run - using pre-release version: $TEST_VERSION (temporary, not committed )"
299+ echo "Test run - using pre-release version: $TEST_VERSION (would be $NEXT_VERSION in prod, temporary build only )"
288300 else
289301 # Production - use current version
290302 CURRENT_VERSION=$(poetry version -s)
0 commit comments