Do not use location spoofing unless explicitly told to do so as part of your workspace instructions. Otherwise, location spoofing represents a breach of the Freelancer Services Agreement.
Note: This guide is written for Xcode 15.1, but the steps should be similar for other Xcode versions.
Download the spoofing project and route simulation file
Download the LocationMovement file.
If predefined Xcode Locations are not enough for the test, download the GPX file for route simulation.
Download update_fake_route_here.gpx for movement simulation from MIT to Harvard.
You can create the position coordinate by your needs using online generators, such as https://gpxgenerator.com/
Install Xcode on your Mac
If you don’t have Xcode installed:
Sign in with your Apple ID.
Register your Apple developer ID.
Note: There is no need to enroll (you would have to pay). Just register your account and accept the “Registered Apple Developer Agreement”.
Download and install the latest Xcode.
Note: You don't need a developer license to run the project.
Log in to Xcode.
Set up the spoofing project in Xcode
Uncompress the LocationMovement zip file.
Open the project in Xcode: File > Open > LocationMovement.xcodeproj
Add the route simulation file update_fake_route_here.gpx to the project (drag and drop) and delete the “red color - update_fake_route_here”.
Configure the LocationSpoofing project.
In XCode, Click LocationMovement > General.
In the Identity section, make sure the Bundle Identifier is a unique string, as it’s necessary to sign certificates. Add a suffix to the name (the following example uses LocationMovement, but it can be anything).
Set the Minimum Deployments to match the iOS version of your device.
In the Signing section, make sure your name is selected as the Team.
Connect your iOS device to your Mac and select it as the build destination.
To start the build, click Play.
When the build is complete, you see Build succeeded (you might be asked to allow access for codesign > Always allow).
If you device is not set to trust developer profiles, you see an error.
Fix it on your iOS device (Settings > General > Device Management > Developer App > Trust your developer profile > Trust).
Click Play again.
When the build succeeds, the LocationMovement app opens on your iOS device.
Navigate to the map app of your choice > Your location in the map should change to Cambridge, Massachusetts, USA.
Run the simulation with a different GPX file
Method 1
In Xcode, drag and drop your new GPX file.
Run the route simulation: Click Debug > Simulate Location > File name.
Method 2
At the top of Xcode, click LocationMovement > Edit Scheme...
In the dialog: Click Run > Click Options > Make sure Allow Location Simulation is selected and for Default Location select “update_fake_route_here”.
Next Step: If you have a new GPX file:
Click “update_fake_route_here”.
Paste the new XML file from your downloaded GPX file.
Click Play (to create new build on your device).
The location is simulated without needing to Click Debug.
Understanding the GPX file
Dynamic Position
Dynamic position means that your position is not static in one location. So your GPX file has a lot of <wpt></wpt> elements, which include time. The difference in time between each of these elements gets your speed.
Static Position
With a static position, you have only 1 <wpt></wpt> element because you are staying at the same position.
#TestlioBot