Reading this may help you:
http://robotframework.googlecode.com/hg/doc/userguide/RobotFrameworkUserGuide.html#test-library-scope
Thomas
>
>
> On Mar 14, 12:14 pm, 磁针石 <xurongzh...@gmail.com> wrote:
>> Hi, all:
>>
>> I want to use Telnet Library to interact with 3 Hosts at the same
>> time. I do not want to use Open Connection to switch host. Can I do it
>> like Python?
>>
>> sessionA = telnetlib.Telnet(hostA)
>> sessionB = telnetlib.Telnet(hostB)
>>
>> Thanks!
>>
>> *** Setting ***
>> Test Setup
>> Test Teardown
>> Force Tags quickstart
>> Default Tags example smoke
>> Library OperatingSystem
>> Library Telnet
>>
>> *** Test Case ***
>> Telnet
>> Open Connection 172.23.191.253
>> Login andrew 123456
>
> --
> You received this message because you are subscribed to the Google Groups "robotframework-users" group.
> To post to this group, send email to robotframe...@googlegroups.com.
> To unsubscribe from this group, send email to robotframework-u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/robotframework-users?hl=en.
>
Why not? That's exactly how using multiple connections has been designed.
> Can I do it like Python?
>
> sessionA = telnetlib.Telnet(hostA)
> sessionB = telnetlib.Telnet(hostB)
Not exactly like this, but importing the library multiple time and
giving it different name using `WITH NAME` syntax could work:
http://robotframework.googlecode.com/hg/doc/userguide/RobotFrameworkUserGuide.html#setting-custom-name-to-test-library
Cheers,
.peke
--
Agile Tester/Developer/Consultant :: http://eliga.fi
Lead Developer of Robot Framework :: http://robotframework.org