Forum Discussion

dougan76's avatar
dougan76
Frequent Visitor
5 years ago
Solved

Unable to access file names from shared network path in “Directory” Data Source

Detailed problem statement:

  • ReadyAPI Version 2.2.0 composite project has been created with “Javascript” language. We were in need to automate the validation of the output files.

When we use Directory and give shared network drive as \\<servername>\<foldername>, we were not getting any output.

But if we pass directory path as absolute as “C:\SLP”, we are able to get the output.

 

Would need help to find a way to get the output of fileNames from Directory Datasource when we give "Network path"

  • Hi dougan76 

     

    Sorry - I just want to clarify - you say that if you use the UNC network drive mapping style it doesnt work - but then you say if you use the absolute C:\SLP it does work - but C:\SLP is relative not absolute.  Sorry - I'm not picking holes here - I just want to be clear.

     

    The Universal Naming convention (which is absolute) of a network drive = \\servername\sharename\foldername

     

    Have you specified the sharename in the path when trying to map to the correct folder?

     

    If this doesn't work - you could try the relative drive mappings R:\foldername - and strictly speaking unless you are using floating licenses - you won't be running the ReadyAPI! project on multiple machines so you don't need to worry about different  people's machines having different network drive mappings.  I suppose you could ensure that EVERYONE who is executing the project have the same network drive mappings so there's no problem - but I appreciate you don't want to use relative drive mappings in this case

     

    Obviously using the relative drive mappings wont work on any machine that doesn't actually have the drive mapped!

     

    Cheers

     

    richie

2 Replies

  • richie's avatar
    richie
    Community Hero

    Hi dougan76 

     

    Sorry - I just want to clarify - you say that if you use the UNC network drive mapping style it doesnt work - but then you say if you use the absolute C:\SLP it does work - but C:\SLP is relative not absolute.  Sorry - I'm not picking holes here - I just want to be clear.

     

    The Universal Naming convention (which is absolute) of a network drive = \\servername\sharename\foldername

     

    Have you specified the sharename in the path when trying to map to the correct folder?

     

    If this doesn't work - you could try the relative drive mappings R:\foldername - and strictly speaking unless you are using floating licenses - you won't be running the ReadyAPI! project on multiple machines so you don't need to worry about different  people's machines having different network drive mappings.  I suppose you could ensure that EVERYONE who is executing the project have the same network drive mappings so there's no problem - but I appreciate you don't want to use relative drive mappings in this case

     

    Obviously using the relative drive mappings wont work on any machine that doesn't actually have the drive mapped!

     

    Cheers

     

    richie