Detecting Automation with Existing Software
If you use browser automation software, such as Selenium, PhantomJS, or others for testing purposes, you can set up the Smartling's Context Capture Chrome Extension to integrate with your existing test scripts and take a snapshot and any point in a script.
- In Chrome, right-click the Chrome Extension icon and select Options
- Check Detect Automation.
Automation Tool
Smartling's Context Capture Chrome Extension can be automated to capture context for an entire website. The Automation Tool is only available for Application Resource Files projects.
- In Chrome, navigate to Chrome > Preferences > Extensions and click Options.
- Select Automation Tool.
- Drag your site’s sitemap.xml file into the marked area.
In your sitemap.xml file, you can create a<url-list>
node populated with a list of URLs you wish to contextualize. You can also preload your Project UID and API V1 key by adding this code at the top of your sitemap:<smartlingconfig>
<apikey>#######</apikey>
You can download a custom sitemap template here.
<projectUID>#######</projectUID>
</smartlingconfig>
4. Set up the automation tool by completing all the following fields:
- Project UID: Can be found on the Dashboard at Project Settings > API.
- API Key: Can be found on the Dashboard at Project Settings > API. Note, the API Key required is the V1 key and not the V2 key.
- Wait: Instructs the Chrome Context Capture Extension to wait X milliseconds after loading a page to take a snapshot. Use this feature if you have JavaScript that executes on loading a page.
- Advanced: Allows you to execute custom JavaScript on each page before taking a snapshot.
- URL Filter: Filters URLs by text. Snapshots will only be taken of URLs matching your filter text.
- Test Mode: If checked, the Chrome Context Capture Extension will crawl the selected URLs, but will not take snapshots. You can also click test next to any URL to view a preview snapshot for that URL.
5. Click Start. The Automation Tool will capture a snapshot of each selected URL and match the snapshots to any matching strings in your project.
By default, the extension will not override existing context.