ATF for Incident management

SuganyaV6003655
Tera Contributor

Can anyone shareme the steps to create ATF for incident management(ITSM)

 

Please share me the step by step for Incident lifecycle

 

User creates a new incident , User assigns an incident to a group or user,Update incident status to In Progress,

Place incident on hold, Resolve an Incident, Close a resolved incident

 

I required all the steps, as i tried but it was failing in the first step while impersonating the user

 

Thanks in advance

2 REPLIES 2

PoonkodiS
Giga Sage

Here  for the Incident lifecycle:

  •  

    • Create a User: Named "Test Caller" (no roles).

    • Create a User: Named "Test Agent" (add itil role).

  • 1. Incident Creation:

    • Impersonate: "Test Caller".

    • Open a New Form: Table: incident.

    • Set Field Values: Short description = "ATF Test".

    • Submit a Form: (Saves the record for the next steps).

  • 2. Assignment & In Progress:

    • Impersonate: "Test Agent".

    • Open an Existing Record: Select the incident created above.

    • Set Field Values: State = In Progress, Assignment group = Service Desk, Assigned to = "Test Agent".

    • Update a Form.

  • 3. Place On Hold:

    • Set Field Values: State = On Hold, On hold reason = Awaiting Caller.

    • Update a Form.

  • 4. Resolve Incident:

    • Set Field Values: State = Resolved, Resolution code = Solved, Resolution notes = "Fixed via ATF".

    • Click a UI Action: Click the Resolve button.

  • 5. Close Incident:

    • Set Field Values: State = Closed.

    • Click a UI Action: Click Close Incident or Update.

Refer : https://www.servicenow.com/community/itsm-forum/in-atf-i-have-created-few-of-the-steps-for-incident-...

Tanushree Maiti
Tera Patron

Hi @SuganyaV6003655 

 

1. Create the Test Record

  • Navigate to Automated Test Framework > Tests and select New.
  • Enter a meaningful test name (for example, ITSM – End-to-End Incident Lifecycle Test) and save the record.

2. Configure Test Steps

Use the Add Test Step option in the related list to build the test scenario:

Step 1: Impersonate a User

  • Add an Impersonate step to simulate either a standard end user or an ITIL user.

Step 2: Open a New Incident Form

  • Select the Incident [Incident] table and choose the required form view.

Step 3: Populate Required Fields

  • Enter values for mandatory fields such as Caller and Short Description.

Step 4: Submit the Record

  • Use the Click UI Action step and select Submit to create the incident.

3. Verify Incident Creation

  • Add a Record Query or Record Validation step to confirm that the incident record has been successfully created in the system.

4. Validate the Incident Lifecycle

Extend the test to verify state transitions by impersonating an ITIL user and progressing the incident through its lifecycle.

Impersonate an ITIL User

  • Select a user who belongs to the appropriate assignment group.

Open the Created Incident

  • Query and open the incident record generated earlier in the test.

Move the Incident to In Progress

  • Update the State field to In Progress and save the record.

Validate Mandatory Resolution Fields

  • Confirm that the incident cannot be resolved until required fields such as Resolution Code and Resolution Notes are populated.

Resolve the Incident

  • Populate the necessary resolution details, change the State to Resolved, and submit the update.

5. Execute the Test

  • Click Run Test and monitor the Automated Test Framework as it executes the workflow and validates each step.

Refer : https://www.youtube.com/watch?v=aMoARIMpvks

https://www.youtube.com/watch?v=37RRu2kZTkQ

Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti
In this video, learn the complete Incident Management Lifecycle in ServiceNow explained in a simple and structured way. We walk through each stage of the lifecycle - from when an incident is reported to when it is resolved, closed, or cancelled. This explanation helps you understand how ServiceNow
Automated Test Framework (ATF) - Incident Lifecycle - D2 ServiceNow ATF, or Automated Test Framework, is a feature in the ServiceNow platform used to automate the process of creating and running functional tests for applications, customizations, and configurations. It reduces the time and ...