need help in automating different locales app through single scenario file.

38 views
Skip to first unread message

lll

unread,
Apr 30, 2015, 2:05:09 AM4/30/15
to frank-...@googlegroups.com
hi,

I want to automate an app which uses different international language like french, german etc... My objective is to write single scenario which can be re-used for different international language through passing the particular language accessibility labels. How to accomplish this without writing multiple scenario file for different international language?

Thanks

Michael Buckley

unread,
Apr 30, 2015, 2:30:52 PM4/30/15
to frank-...@googlegroups.com
Hi,

Frank doesn't currently have this capability built-in. It has no notion of locale.

Your best bet to achieve this goal is to write some Ruby code to parse your .strings files and create a function that can localize your Ruby strings in your testing scripts.

I'm sorry that I don't have a better solution.

--
You received this message because you are subscribed to the Google Groups "Frank" group.
To unsubscribe from this group and stop receiving emails from it, send an email to frank-discus...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

lll

unread,
May 4, 2015, 4:21:19 AM5/4/15
to frank-...@googlegroups.com
Thanks for your response.

Can you please provide me with the steps to parse the .string file? Any documentation in this regard will be helpful.

Thanks and Regards,

Michael Buckley

unread,
May 4, 2015, 3:51:07 PM5/4/15
to frank-...@googlegroups.com
It looks like there's a .strings parser on GitHub.


If you want to write your own, Apple has documentation on the file format. It's very simple.


I would recommend adding a method to your env.rb file to parse the Localizable.strings file in your source directory. Then, add a function to that file which takes a language and key from Localizable.strings and returns the localized string. Then use that function in all your step definitions.


--
Reply all
Reply to author
Forward
0 new messages