Calabash xamarin - xamarin.ios

I am not able to generate Snippets with Regular Expressions in Xamarin.iOS Calabash.
Eg..
Feature:ABC
Given I launch my app
Then I should see text "Home"
Snippets generated:
Then(/^I should see text "Home"$/) do
pending #Write code here that turns the phrase above into concrete actions
end
I have tried passing "(.*)", "(.*?)" as well as "([^\"]*)"
Can anyone please tell me? Whether my installation process has missed out something or there is a problem somewhere else?

Then(/^I should see text "Home"$/)
If you have a Step:
Then I should see text "Home"
The definition should be:
Then(/^I should see text "([^"]*)"$/) do |arg1|
end
What is actually happening? And how are you running cucumber?

Related

How to redirect to a website in Godot Web

I'm planning on trying to see if it's possible to make a website in Godot(Yes, I know I shouldn't I just want to try just to try). I thinking about and looking over the features I need and I have one problem.
I just need a way for a person to press a button and get redirected to my itch games. I don't care if it creates a new tab or changes the current tab. Thank you for any help.
If you dont export to web you can call
OS.shell_open("url")
Sadly this does not work in an html export. A solution I found for myself is the JavaScript Interface. As the name suggested it allows you to execute Javascript.
So to open a URL you could connect the pressed signal of a button to something like this:
if OS.has_feature('JavaScript'):
JavaScript.eval("""
window.open('https://google.com', '_blank').focus();
""")
This will open a new tab in the active browser.
I also found an article on the godot site, basically asking the same question (https://godotengine.org/qa/46978/how-do-i-open-richtextlabel-bbcode-links-in-an-html5-export). Here they tried to use an RichTextLabel with BBCode.
The solution did not work for me, when I tested it, though.
As pointed in the comments you can try OS.shell_open, for example:
OS.shell_open("https://example.com")
That only works if it is not an HTML export.
Your other alternative is to eval JavaScript, for example this navigates the current tab:
JavaScript.eval("window.location.href='https://example.com'")
Which only works if it is an HTML export.
Since that only works for an HTML export and the other does not work on an HTML export... If you need both you can do this:
if OS.get_name() == "HTML5":
JavaScript.eval("window.location.href='https://example.com'")
else:
OS.shell_open("https://example.com")
See also Close a game in Godot.

Test for text on a page

Very basic question but I can't figure it out.
How do I test for the existence of a piece of text on a page?
e.g. does the word "mouse" exist on this page? I'm using playwright and node.js
Thanks!
You can do that via page.waitForSelector(). Example:
await page.waitForSelector('text=mouse')
See on playwright.dev for the full documentation and how you can use the text selectors in other scenarios.

DialogFlow: 'Add Response' not working in Web Demo

As you can see from the image below, putting two separate 'text response' buttons gives me a two line response.
However, I only get either one of the responses (at random) when I use the Web Demo integration. Either 'Hi, welcome!' or 'How may I help?'
Anyone got any ideas why? Thanks!
Not sure where my image link went... anyway read a few Google forums that said this isn't possible. Solved the problem by just pressing space until it went onto a new line.
When you are in Default responses tab, then it gives two options: Text response, custom payload
You should select Google assistant tab before clicking the add response button. Thus You can see all options about responses.

Change Touch Menu Items in Compass Sample

Just getting the Google Glass GDK (19) running with Eclipse Java and its all up and running fine. ADB etc all good.
And now experimenting with the Compass Sample code. One thing I would like to try and pin down is basically customising whats there - a simple thing being the Touch Menu text which is "Show A Compass".
Can that be changed? That's all I want to do! However, strings.xml alters app_name only and the XML Trigger def of SHOW_A_COMPASS seems locked down somewhere. I guess that's what I am trying to discover.
Any pointers appreciated.
Thanks
Doug
You specify the trigger command in an XML file in your resources. In compass this is res/xml/compass_show.xml. In there, you will see a <trigger> tag, which you should change to one of the constants in VoiceTriggers.Command. So if you wanted to use the voice command "Find a product" you could use something like
<?xml version="1.0" encoding="utf-8"?>
<trigger command="FIND_A_PRODUCT" />
You can use your own voice commands... but only for testing purposes. Glassware that is reviewed and distributed through MyGlass must use a defined command. (You can, however, request a voice command be included in a future Glass update. If you plan to do this, you should request it as early as possible.)
See https://developers.google.com/glass/develop/gdk/voice for the full details.

review form do not show up after clicking on "Be the first one to review"?

i have checked that review is both enabled from Advance tab under system -> configuration and also from catalog tab.
also i have changed the files with original one but still not getting the form on frontend :( Although link to show review is showing .
can anyone please help ?
DO category settings like anchor set to NO has any impact on it ?
i did even replace complete folders of layout and template even then it didn't change. But when I commented app/design/frontend/mythemefolder,
it did show up.
But how can i show it on mytheme ?
i guess someone played with my style sheet and i found that this class ".product-collateral" in stylesheet was given "display = NOne"
it took me too long as i was examining the code but anyhow problem solved.

Resources