how generate logs and reports in ruby capybara rspec - ruby

I am new to this technology and I am working on an automation framework, ruby-capybara-rspec. And this project is in POC state. Now I want to generate "Logs" and "reports" as well. Please help me if there is any default/inbuilt functionality to do so or is there any specific gem I can use to achieve it. Thank you in advance.
PS: There is no specific ask from the client so I can bring my own logging and report to this framework.

From the official documentation:
rspec example_spec.rb --format documentation --out rspec.txt

Related

Is there any plugin available for breakman in rubymine?

Im planning to use brakeman in my ruby app , is there any way to use brakeman in rubymine ? (able to configure robocop)
At the moment there's no plugin for that, but there's a feature request on RubyMine's tracker for adding support to Brakeman so your vote is welcome: https://youtrack.jetbrains.com/issue/RUBY-17517

Moodle with Ruby On Rails

Currently, I am working on a rails application which requires the user to be registered automatically in the moodle. I searched for it and found these gems,
moodle-api: https://github.com/getsmarter/moodle-api
moodle_rb: https://github.com/jobready/moodle-rb/
moodle: https://github.com/robertboloc/moodle
But, nothing seems to work for me. I even searched on youtube but found nothing with the rails.
However, using the moodle_rb gem I was able to create an object which returned me the sites info using the sites_info function. Other than that I am unable to use any of the web services of the moodle. I have created an external service and added some functions like auth_email_get_signup_settings and auth_email_signup_user which accepts none parameters.
May anyone guides me through this? or even a minor help would also be great.
I am using a token to create the object.
Thanks in advance.
Can you show us how you tried to configure your gems? For example, according to the docs the moddle-api gem requires a configuration like:
Moodle::Api.configure do|c|
c.host = 'http://my_moodle_instance.com'
c.token = 'mytoken'
end
If you did configure the gem like the above, can you show some of the code that you tried to call once the gem was installed and configured?

How to use ckan gem Comprehensive Knowledge Archive Network

Does anyone have a link to a tutorial on how to use the Ruby 'ckan' gem (Comprehensive Knowledge Archive Network). I want to access gov.uk data , I downloaded the gem but how do I get to the data ? The documentation seems a bit sparse in this area
Many thanks for any help. My googling has turned up nothing so far so any help is much appreciated.
The CKAN gem's documentation is in their repository at https://github.com/apohllo/ckan. Note that it's not OKFN's CKAN repository.
Looking at their code, it seems that they hardcoded http://datahub.io API endpoint at https://github.com/apohllo/CKAN/blob/master/lib/ckan.rb#L2. So you won't be able to access data.gov.uk without changing their code.
But, thanks to Ruby being such a dynamic language, you could override that constant, as
CKAN::API_BASE = 'http://data.gov.uk/api/1'
Now you could follow their documentation in GitHub, and it should work.
Cheers!

What methods exist to auto-generate ruby client stubs from WSDL files?

I'm using Ruby and the Savon gem to interact with SOAP/WS and would like to auto-generate the client request methods from the WSDL in Ruby.
Before I do this, I'd like to know if there's any other Ruby/SOAP library that does this?
Edit: Please note, I already know this isn't available in Savon out the box, in fact my intention is to add in the feature, I'm in the process checking if this exists somewhere else written in Ruby.
Since it's only few days since you asked this question, and I've run into same problem I've decided to create small script to do that.
Download - save as objects.rb for example and run with _bunde exec objects.rb path_to.wsdl_
https://gist.github.com/4622792
Let me know if it works ^^
Take a look at Savon's spec, it has pretty rich testing environment
I think ads_common by Google is relevant to you.
google-api-ads-ruby/ads_common at master ยท googleads/google-api-ads-ruby
rake generate can create the client libraries automatically from WSDL.
It is specialized for Google Ads, but this notion would be helpful to create a versatile client library automatically from WSDL in Ruby.

The Document for selenium test!

I want to use selenium test to cover my rails project ! but i just find little documents on selenium test . I want someone to give me some documents for selenium test of all types !like website ,pdf ,text etc. you can sent them to my gmail liwh87#gmail.com ,or write under the question. Thank you ,and best regards!
You might start here

Resources