1"use strict";(self.webpackChunkKatalon_Docs=self.webpackChunkKatalon_Docs||[]).push([[12937],{28453:(e,t,a)=>{a.d(t,{R:()=>c,x:()=>o});var s=a(96540);const n={},d=s.createContext(n);function c(e){const t=s.useContext(d);return s.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function o(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(n):e.components||n:c(e.components),s.createElement(d.Provider,{value:t},e.children)}},62385:(e,t,a)=>{a.r(t),a.d(t,{assets:()=>i,contentTitle:()=>o,default:()=>l,frontMatter:()=>c,metadata:()=>s,toc:()=>r});const s=JSON.parse('{"id":"keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords/webui-take-a-screenshot-as-checkpoint","title":"[WebUI] Take Screenshot as a Checkpoint","description":"Description","source":"@site/docs/katalon-studio/keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords/webui-take-a-screenshot-as-checkpoint.md","sourceDirName":"keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords","slug":"/keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords/webui-take-a-screenshot-as-checkpoint","permalink":"/katalon-studio/keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords/webui-take-a-screenshot-as-checkpoint","draft":false,"unlisted":false,"tags":[],"version":"current","lastUpdatedAt":1764053770000,"frontMatter":{"title":"[WebUI] Take Screenshot as a Checkpoint"},"sidebar":"katalon-studio","previous":{"title":"[WebUI] Take Full Page Screenshot as Checkpoint","permalink":"/katalon-studio/keywords/keyword-description-in-katalon-studio/visual-based-web-testing-keywords/webui-take-full-page-screenshot-as-checkpoint"},"next":{"title":"[Mobile] Check Element","permalink":"/katalon-studio/keywords/keyword-description-in-katalon-studio/mobile-keywords/mobile-check-element"}}');var n=a(74848),d=a(28453);const c={title:"[WebUI] Take Screenshot as a Checkpoint"},o=void 0,i={},r=[{value:"Description",id:"description",level:2},{value:"Parameters",id:"parameters",level:2},{value:"Example",id:"example",level:2}];function _(e){const t={h2:"h2",...(0,d.R)(),...e.components};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(t.h2,{id:"description",children:"Description"}),"\n",(0,n.jsxs)("p",{xmlns:"http://www.w3.org/1999/xhtml",className:"p",children:["Take a screenshot of the current viewport to send to TestOps Vision. The captured image will be saved in ",(0,n.jsx)("code",{className:"ph codeph",children:".png"})," format and stored in the ",(0,n.jsx)("code",{className:"ph codeph",children:"keyes"})," folder inn the report folder."]}),"\n",(0,n.jsxs)("p",{xmlns:"http://www.w3.org/1999/xhtml",className:"p",children:["Keyword name: ",(0,n.jsx)("code",{className:"ph codeph",children:"takeScreenshotAsCheckpoint"})]}),"\n",(0,n.jsx)(t.h2,{id:"parameters",children:"Parameters"}),"\n",(0,n.jsxs)("table",{xmlns:"http://www.w3.org/1999/xhtml",className:"table anchor_top_offset",id:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d",children:[(0,n.jsx)("caption",{}),(0,n.jsxs)("colgroup",{children:[(0,n.jsx)("col",{style:{width:"20%"}}),(0,n.jsx)("col",{style:{width:"20%"}}),(0,n.jsx)("col",{style:{width:"20%"}}),(0,n.jsx)("col",{style:{width:"40%"}})]}),(0,n.jsx)("thead",{className:"thead",children:(0,n.jsxs)("tr",{className:!0,children:[(0,n.jsx)("th",{className:"entry anchor_top_offset",id:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1",children:"Parameter "}),(0,n.jsx)("th",{className:"entry anchor_top_offset",id:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2",children:"Parameter Type"}),(0,n.jsx)("th",{className:"entry anchor_top_offset",id:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3",children:"Required"}),(0,n.jsx)("th",{className:"entry anchor_top_offset",id:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4",children:"Description"})]})}),(0,n.jsxs)("tbody",{className:"tbody",children:[(0,n.jsxs)("tr",{className:!0,children:[(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",rowSpan:1,colSpan:1,children:"checkpointName"}),(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",rowSpan:1,colSpan:1,children:"String"}),(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",rowSpan:1,colSpan:1,children:"Yes"}),(0,n.jsxs)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",rowSpan:1,colSpan:1,children:["Represents the name of the image on TestOps Vision. On local machine, this name will be appended with TestOps Vision prefix (",(0,n.jsx)("code",{className:"ph codeph",children:"keyes-"}),")."]})]}),(0,n.jsxs)("tr",{className:!0,children:[(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",children:"flowControl"}),(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",children:"FailureHandling"}),(0,n.jsx)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",children:"Optional"}),(0,n.jsxs)("td",{className:"entry",headers:"topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__1 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__2 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__3 topic-5016__f809b6d1-43cb-4401-97b5-d8a8f410a28d__entry__4 ",children:["Specify ",(0,n.jsx)("a",{className:"xref",href:"/katalon-studio/maintain-tests/configure-failure-handling-settings-in-katalon-studio",children:"failure handling "}),"schema to determine whether the execution should be allowed to continue or stop."]})]})]})]}),"\n",(0,n.jsx)(t.h2,{id:"example",children:"Example"}),"\n",(0,n.jsxs)("ul",{xmlns:"http://www.w3.org/1999/xhtml",className:"ul",children:[(0,n.jsx)("li",{className:"li",children:(0,n.jsxs)("div",{className:"p",children:[" You want to take a screenshot as checkpoint named ",(0,n.jsx)("code",{className:"ph codeph",children:"current_viewport"})," for TestOps Vision and use default ",(0,n.jsx)("a",{className:"xref",href:"/katalon-studio/maintain-tests/configure-failure-handling-settings-in-katalon-studio",children:"failure handling"}),":",(0,n.jsx)("pre",{className:"pre codeblock",children:(0,n.jsx)("code",{children:"WebUI.takeScreenshotAsCheckpoint('current_viewport')"})})," "]})}),(0,n.jsx)("li",{className:"li",children:(0,n.jsxs)("div",{className:"p",children:["You want to take a screenshot as checkpoint named ",(0,n.jsx)("code",{className:"ph codeph",children:"full_view"})," for TestOps Vision, and need the test to keep running regardless of this step having failed or passed: ",(0,n.jsx)("pre",{className:"pre codeblock",children:(0,n.jsxs)("code",{children:["import com.kms.katalon.core.model.FailureHandling as FailureHandling","\n","\n","WebUI.takeScreenshotAsCheckpoint('full_view', FailureHandling.CONTINUE_ON_FAILURE)"]})})]})})]})]})}function l(e={}){const{wrapper:t}={...(0,d.R)(),...e.components};return t?(0,n.jsx)(t,{...e,children:(0,n.jsx)(_,{...e})}):_(e)}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.