This is a sample project demonstrating how to use GitHub Copilot effectively with Katalon Studio test automation projects.
Katalon Studio supports GitHub Copilot through its built-in integration. Follow these steps to configure it:
- GitHub Copilot subscription - You need an active GitHub Copilot subscription (Individual, Business, or Enterprise)
- Katalon Studio 10.4.0 or later with GitHub Copilot support - GitHub Copilot support is still in preview, so ensure you have the latest version of Katalon Studio
When you first start Katalon Studio with GitHub Copilot integration, you may see a quick start screen. You can close this window by clicking the X in the upper right corner.
You may also see release notes for the current Copilot release:
In the lower left corner of the main project window, you should see a Copilot icon (a sparkle or star symbol). Clicking on this icon gives you access to all Copilot features:
-
Sign in to GitHub
- Click on the Copilot icon in the lower left corner
- Select "Sign in to GitHub" from the menu
-
Device Activation
- A dialog will appear with a device code
- Click "Copy Code and Open" to copy the code and open your browser to GitHub's device activation page
-
GitHub Authentication Flow
- Your browser will open to GitHub's device activation page
- Paste the activation code when prompted
- Click Continue and then Authorize to grant Katalon Studio access to GitHub Copilot
-
Verify Connection
- Once authorized, you should see a confirmation screen on GitHub
- In Katalon Studio, you'll see confirmation that you're signed in
The Copilot menu in the lower left corner provides access to:
- Open Chat - Opens the Copilot Chat window
- Sign in/Sign out - Manage your GitHub authentication
- Edit Preferences - Configure MCP (Model Context Protocol) servers
- Help and documentation - Access Copilot resources
Once configured, GitHub Copilot will:
- Provide inline code suggestions as you type in the Script Editor
- Suggest complete functions and test steps based on comments
- Autocomplete Katalon keywords and custom methods
- Generate test automation code following Katalon best practices
Keyboard Shortcuts:
- Accept suggestion:
Tab - Dismiss suggestion:
Esc - Show next suggestion:
Alt + ](Windows/Linux) orOption + ](macOS) - Show previous suggestion:
Alt + [(Windows/Linux) orOption + [(macOS)
GitHub Copilot includes a chat interface for interactive assistance:
-
Opening Chat
- Click the Copilot icon in the lower left corner
- Select "Open Chat"
- The chat window will open alongside Studio's Console, Log Viewer, etc.
-
Using Chat
- Ask questions about your code, Katalon best practices, or test automation
- Get explanations of existing code
- Request code generation with specific requirements
- The chat window can be relocated by dragging and dropping
Agent mode is an advanced feature that autonomously translates your intent into code:
- What it does: Analyzes your project, breaks down requests into actionable steps, and executes changes across multiple files
- How to use: Simply provide a prompt describing what you want to accomplish
- Benefits: Handles complex, multi-file changes automatically
- Example: "Create a new test suite for login scenarios with data-driven testing"
You can configure MCP servers for extended functionality:
-
Click the Copilot icon and select "Edit Preferences..."
-
Or click the tools icon in the lower right of the chat window
-
Configure MCP servers using standard syntax
-
Enable/disable specific servers and tools
-
Access MCP registries for additional integrations
The .github/copilot-instructions.md file is a repository-scoped instruction file that provides GitHub Copilot with specialized knowledge about Katalon Studio projects.
GitHub Copilot supports custom instruction files that give the AI assistant context-specific guidance. When you work in a repository containing this file, Copilot automatically uses the instructions to generate more accurate, project-appropriate suggestions.
The file located at .github/copilot-instructions.md contains:
-
Project Structure Documentation
- Explains the standard Katalon Studio directory layout
- Describes what each folder contains (
Test Cases/,Scripts/,Keywords/, etc.)
-
File Format Specifications
- Details the XML schemas for test cases, test suites, test objects, and profiles
- Explains the relationship between test case metadata and Groovy scripts
- Provides examples of proper file structure
-
Best Practices
- Katalon-specific coding conventions
- Proper use of built-in keywords (
WebUI,WS,Mobile) - Data-driven testing patterns
- Security considerations (avoiding hardcoded credentials)
-
Domain-Specific Guidance
- API testing patterns
- Web UI automation approaches
- BDD/Cucumber integration
- Custom keyword development
When Copilot has access to these instructions, it can:
- Generate compliant code: Suggestions follow Katalon's file structure and XML schemas
- Use correct APIs: Copilot knows the proper Katalon keyword syntax and imports
- Follow conventions: Generated code matches your project's patterns (static imports, relative paths, etc.)
- Avoid anti-patterns: Instructions warn against common mistakes like hardcoded credentials or fixed delays
- Understand context: Copilot knows how test cases, scripts, and object repositories relate to each other
Without instructions, Copilot might suggest:
// May not follow Katalon conventions
driver.findElement(By.xpath("//button")).click()With instructions, Copilot suggests:
import static com.kms.katalon.core.testobject.ObjectRepository.findTestObject
import com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords as WebUI
WebUI.click(findTestObject('Page/Submit_Button'))The copilot-instructions.md file should be:
- Version controlled: Committed to the repository so all team members benefit
- Updated regularly: Modified when project conventions change or new patterns emerge
- Project-specific: Customized to reflect your team's standards and practices
You can extend the existing file with:
- Custom keyword documentation
- Project-specific test data patterns
- Team coding standards
- Integration with CI/CD pipelines
- Clone this repository or use it as a template
- Configure GitHub Copilot in Katalon Studio (see steps above)
- Open any script file in the
Scripts/folder or create a new test case - Start typing and observe how Copilot suggestions follow Katalon best practices
- Experiment with comments like
// Navigate to login page and enter credentialsto see Copilot generate complete test steps
If you discover patterns or best practices that should be added to copilot-instructions.md, please submit a pull request with:
- Clear description of the pattern or practice
- Example code demonstrating the recommendation
- Rationale for why it improves code quality or maintainability














