Product Installation and Upgrade testing is always a challenge in automation, Leapwork enables the user to perform such operations easily by altering the registry items and running the silent installation script. The process below defines how to achieve that.
- Go to registry settings HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Security Center
- Add a new DWORD entry with the name ‘UACDisableNotify’ and the value of ‘1’
- Save below script as .vbs extension and note down the path, for example "C:\Scripts\SilentInstall.vbs"
If WScript.Arguments.length = 0 Then
- Set objShell = CreateObject("Shell.Application")
- 'Pass a bogus argument, say [ uac]
- objShell.ShellExecute "wscript.exe", Chr(34) & _WScript.ScriptFullName & Chr(34) & " uac", "", "runas", 1
Else
- 'Add your code here
- WScript.Echo("Usage:elevate Application Arguments")
- Set WSHShell = WScript.CreateObject("WScript.Shell")
- strApp = "C:\Installers\Setup.exe /q"
- WSHShell.Exec(strApp)
End If
- Now user can call this script using Command-line or Start Application block as shown below
The installer will run silently as desired, the user can use this mechanism to install or upgrade their application under test.
For any clarification, please contact our Priority Support.
Comments
0 comments
Please sign in to leave a comment.