Testing
How versions, docs HTML, and unit tests stay in sync.
Version numbers
version.json is the source of truth (MAJOR.MINOR.PATCH.REVISION, for example 1.0.32.1).
- Every real commit (pre-commit hook in
.githooks/pre-commit) increments REVISION and writes the same value into the Windows.csproj, iOSInfo.plist/DTDisplayVersion, and AndroidversionName. Store build (CFBundleVersion/versionCode) increments separately so TestFlight and Play stay unique. - Promote
dev→mainrunsscripts/bump-version-on-commit.ps1 -Release, which increments PATCH and resets REVISION (1.0.32.13→1.0.33.0). - Push to
devthat did not already touchversion.jsonis bumped in Publish Windows zip (-Force) so Cursor commits that skip hooks still move the last digit.
Enable hooks once after clone:
pwsh -File scripts/setup-git-hooks.ps1
About on Windows shows the running exe assembly version. Rebuild and relaunch after a bump. The optional number in parentheses is the website zip (windows-version.json on production).
Markup → HTML
Do not hand-edit docs/*.html, README.html, or site/*.html copies of those docs. Edit markdown, then:
pwsh -File scripts/build-site.ps1
scripts/distribution-docs.txt lists the files that must have HTML. CI Markdown Docs Sync fails if you forget to regenerate.
site/index.html is hand-maintained (marketing / Windows download), not generated from markdown. About “Get the free Windows app” opens the website home (https://droptophone.welchsoftware.net/) — never the .zip, never /download (that path used to serve the zip). On a phone the home page offers email / text / copy so the PC can download. /download and WINDOWS.html only redirect to /.
Unit tests
dotnet test DropToPhone.sln --configuration Release
cd src\DropToPhone.Android
.\gradlew.bat testDebugUnitTest
Windows tests cover DropKinds, Brand labels and URLs, pairing PIN, network hints, version compare, and clipboard note vs path. Android tests cover Brand website/zip/privacy/support, PIN-on-QR parse, hotspot hints, and nicknames.
iOS XCTest is not in the Xcode scheme yet — add it when the next Mac pass happens.