Failed to Upload File - Error Script Test

I create a test case to upload a file with this code: https://pastebin.com/bX8RP0Kb My problem is, why this test case can’t running on the katalon studio. Please, help me to solve this problem.

This is the Screenshot of detail in my test case :

upload-file-on-katalon.png

WebUI.uploadFile(findTestObject(‘Configuration/GlobalConfig/Page_e-service Global Configuratio/upload_file’), ‘~/Download/test/logo.png’)

Can you give the exact path instead of giving ~/Download/test/logo.png

===

so, is it like this?

/home/username/Download/test/logo.png

I suspect you have ~/Dowloads directory, not ~/Download without s.

Therefore your code should be:

/home/username/Downloads

-----------

The bash understands ‘~/Downloads’ to be a directory under your home, but Java does not understand ‘~’.

-----------

If you do not like to code the absolute path, then you can rewrite your code as:

WebUI.uploadFile(    findTestObject('Configuration/GlobalConfig/Page_e-service  Global Configuratio/upload_file'),    "${System.getProperty('user.home')}/Downloads/test/logo.png")

thanks all