While designing Actions in ACCELQ, it’s important to maintain clarity and simplicity—not just for input parameters, but for output parameters as well. Output parameters enable continuity across Scenario steps through parameter linking and shared data flow. However, unnecessary or excessive output parameters can lead to bloated interfaces and hard-to-maintain test logic.
This article outlines best practices to help you manage output parameters efficiently and effectively.
✅ Only Output What’s Needed Right Now
It’s tempting to preemptively define output parameters in anticipation of future use—but this can quickly clutter your Action design.
-
Design outputs based on current needs only. If another Scenario or Action requires a new value later, you can always add output parameters when the need arises—ACCELQ makes this easy.
-
Avoid exposing variables "just in case." Clean interfaces lead to better reusability and less technical debt.
Good Practice: Keep your Action interface focused. Future-proofing should not mean present-bloating.
🧾 Use print log
Instead of Output Parameters for Reporting-Only Values
If a value is only needed for logs, debugging, or reporting, it does not need to be exposed as an output parameter.
-
Use
print log
statements within the Action logic to surface these values in reports. -
This avoids cluttering your parameter list with data that isn’t functionally reused elsewhere.
🗺️ Use Data Maps for Shared or Reusable Data
ACCELQ’s Data Maps are ideal for managing dynamic data that must be shared across Scenarios or between multiple Actions.
-
Instead of passing repetitive outputs, store and retrieve values centrally.
-
This supports clean separation of data and logic while avoiding unnecessary output parameter definitions.
Refer to the article Using Data Map for Dynamic Test Data Management to understand how to effectively implement this pattern in your framework.
Key Benefit: Data Maps reduce the need to pass large or repetitive outputs between Actions by acting as a shared memory across your test logic.
📦 Handling Large or Grouped Data Outputs
If your Action returns multiple related values or large amounts of data, consider these smarter design approaches:
1. Group Values in JSON
-
Bundle related outputs into a single JSON-formatted string instead of creating multiple output parameters.
-
This is especially useful for logically grouped items like user details, product info, or API response data.
Example:
{
"username": "jane_doe",
"role": "admin",
"status": "active"
}
-
ACCELQ offers a rich, no-code JSON utility library to help you create, update, and parse JSON structures easily within Actions.
👉 Explore ACCELQ’s JSON capabilities
2. Write to External Files
-
When dealing with large data blocks or values that need to persist across multiple Scenarios, write to the Agent’s file system.
-
These files can be read by other Actions and Scenarios—even during parallel execution, since each Agent has isolated storage.
-
This is also useful when output needs to be retained for future reference or reporting beyond the test execution.
✅ Summary: Do’s and Don’ts
Best Practice |
Why It Matters |
✅ Output only what’s needed now | Avoid overengineering and keep Actions simple |
✅ Use print log for reporting-only data |
Keeps parameter list clean |
✅ Group related outputs in JSON | Reduces clutter and promotes structure |
✅ Write to external file on Agent | Supports parallel execution and persistent storage |
✅ Use Data Maps for shared dynamic values | Improves modularity and test data management |
❌ Don’t output values “just in case” | Leads to unnecessary complexity |
❌ Don’t create many similar output params | Combine them logically instead |
Comments
0 comments
Please sign in to leave a comment.