ruby_raider 0.3.8 → 0.3.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 106c60b9bd7b4806542ad9f6c21505088644992d6da1214aab5a6ba01e4556ef
4
- data.tar.gz: b8cb6da9029bba9ee34d81e6dd182bb0aee8f5fe7d876a7f4b578dcf78a4948a
3
+ metadata.gz: 142c09c13840d275edad19efb9ea01393831acdeb996848033af48624a535eb3
4
+ data.tar.gz: 485fdcefeac72106e05027c452beedeef727ca63b105d7e4c8d63056f783c74a
5
5
  SHA512:
6
- metadata.gz: 0a3c71354a97dda80868e5626d2e50e4196856c4c51088e5b02650cb19481c65ce67b32d6033c1306ebced70df5b1e608b1caaf18c4539ae40a8de7b38f6970a
7
- data.tar.gz: 886bbdd0a0ca5772e76a62f4a76a73e40269229465eb2b42829da7473f463c0aeab83e9b9a6f7267bbfff7b772275bdff40af3139bb75f4a67ef83d6c7b1b874
6
+ metadata.gz: ac631cb2cb6b93ae71950f278c8b8306e4dae4170858c0b65e515ceebd763b93126ee6d8f45410633bc1ef3611d3ccdec0bb69e2f47137903dcd3ce1fc394131
7
+ data.tar.gz: '05874e4a92b5e7c875b42ae27bbc5e5c937bf6ee5c5678ceb084ae76697b4e2e03f5227b51c6e0a9c925d1ae861952ae822ff375a96bab193c5e8246499ec92b'
data/README.md CHANGED
@@ -3,21 +3,33 @@
3
3
  [![Gem Version](https://badge.fury.io/rb/ruby_raider.svg)](https://badge.fury.io/rb/ruby_raider)
4
4
  [![Rubocop](https://github.com/RubyRaider/ruby_raider/actions/workflows/rspec.yml/badge.svg)](https://github.com/RubyRaider/ruby_raider/actions/workflows/rspec.yml)
5
5
 
6
- This is a gem to make setup and start of UI automation projects easier.
7
-
8
- You can find more information and updates on releases in : [https://ruby-raider.com/](https://ruby-raider.com/)
9
-
10
- Just do:
11
-
12
- **gem install ruby_raider**
13
-
14
- then do:
15
-
16
- **raider new [name_of_project]**
17
-
18
- and you will have a new project in the folder you are in.
19
-
20
- Currently we support:
6
+ <!-- PROJECT LOGO -->
7
+ <br />
8
+ <div align="center">
9
+ <a href="https://github.com/RubyRaider/ruby_raider">
10
+ <img src="https://rubyraiderdotcom.files.wordpress.com/2022/05/logo_transparent_background-1.png" alt="Logo">
11
+ </a>
12
+ <h1 align="center">Ruby Raider</h1>
13
+ <p align="center">
14
+ This is a gem to make setup and start of UI automation projects easier.
15
+ <br />
16
+ <a href="https://github.com/RubyRaider/ruby_raider#getting-started"><strong>Explore the docs »</strong></a>
17
+ <br />
18
+ <br />
19
+ <a href="https://rubygems.org/gems/ruby_raider">Rubygems</a>
20
+ ·
21
+ <a href="https://github.com/RubyRaider/ruby_raider/issues">Report Bug</a>
22
+ ·
23
+ <a href="https://github.com/RubyRaider/ruby_raider/issues">Request Feature</a>
24
+ </p>
25
+ <p align="center"> For more information and updates on releases, see <a href="https://ruby-raider.com">https://ruby-raider.com</a></p>
26
+ </div>
27
+
28
+ ## What is ruby raider?
29
+
30
+ Ruby Raider is a generator and scaffolding gem to make UI test automation easier
31
+
32
+ ### At the moment Ruby raider supports
21
33
 
22
34
  * Generating a framework with Cucumber and Selenium
23
35
 
@@ -31,44 +43,73 @@ Currently we support:
31
43
 
32
44
  * Generating a framework with Cucumber and Appium for IOS
33
45
 
34
- In order to run the Appium tests, download the example [app](https://github.com/cloudgrey-io/the-app/releases/tag/v1.10.0).
46
+ ***In order to run the Appium tests, download the example [app](https://github.com/cloudgrey-io/the-app/releases/tag/v1.10.0).***
35
47
 
36
48
  This works in all the platforms (Tested on Mac OS, Linux and Windows).
37
49
 
38
- **Ruby raider provides the following list of commands**
50
+ ## Getting started
51
+
52
+ To get the project up and running.
53
+
54
+ **Just do:**
55
+
56
+ ```ruby
57
+ gem install ruby_raider
39
58
  ```
59
+
60
+ **Then do:**
61
+
62
+ ```ruby
63
+ raider new [name_of_project]
64
+ ```
65
+
66
+ Then a TUI/CLI will appear where the configuration of which frameworks you want to be generated/scaffolded can be selected.
67
+
68
+ Select the ones you will like to work with.
69
+
70
+ ### Ruby raider provides the following list of commands
71
+
72
+ ###### Anything between square brackets([...]) is where your imput goes
73
+
74
+ ```ruby
40
75
  Commands:
41
- raider browser [BROWSER] # Sets the default browser for a project
76
+ raider browser [BROWSER] # Sets the default browser for a project
42
77
 
43
78
  raider browser_options [OPTIONS] # Sets the browser options for the project
44
79
 
45
- raider feature [FEATURE_NAME] # Creates a new feature
80
+ raider feature [FEATURE_NAME] # Creates a new feature
46
81
 
47
- raider help [COMMAND] # Describes available commands or one specific command
82
+ raider help [COMMAND] # Describes available commands or one specific command
48
83
 
49
- raider helper [HELPER_NAME] # Creates a new helper
84
+ raider helper [HELPER_NAME] # Creates a new helper
50
85
 
51
- raider new [PROJECT_NAME] # Creates a new framework based on settings picked
86
+ raider new [PROJECT_NAME] # Creates a new framework based on settings picked
52
87
 
53
- raider page [PAGE_NAME] # Creates a new page object
88
+ raider page [PAGE_NAME] # Creates a new page object
54
89
 
55
- raider path [PATH] # Sets the default path for scaffolding
90
+ raider path [PATH] # Sets the default path for scaffolding
56
91
 
57
- raider raid # Runs all the tests in a project
92
+ raider raid # Runs all the tests in a project
58
93
 
59
- raider scaffold [SCAFFOLD_NAME] # Generates everything needed to start automating
94
+ raider scaffold [SCAFFOLD_NAME] # Generates everything needed to start automating
60
95
 
61
- raider spec [SPEC_NAME] # Creates a new spec
96
+ raider spec [SPEC_NAME] # Creates a new spec
62
97
 
63
- raider url [URL] # Sets the default url for a project
98
+ raider url [URL] # Sets the default url for a project
64
99
  ```
65
100
 
101
+ Ruby raider also supports scaffolding:
102
+
103
+ * To create a new page object you do: ```raider page [PAGE_NAME]```
104
+ * To create a new spec you do: ```raider spec [SPEC_NAME]```
105
+ * To create a new feature you do: ```raider feature [FEATURE_NAME]```
106
+
66
107
  It's possible to add the option --path or -p if you want to specify where to create your features, pages, helpers and
67
108
  specs.
68
109
 
69
110
  If you want to set the default path for the creation of your features, helpers and specs:
70
111
 
71
- ```
112
+ ```ruby
72
113
  raider path [PATH_NAME] --feature or -f
73
114
  raider path [PATH_NAME] --spec or -s
74
115
  raider path [PATH_NAME] --helper or -h
@@ -52,9 +52,17 @@ class UtilityCommands < Thor
52
52
  map '-bo' => 'browser_options'
53
53
 
54
54
  desc 'raid', 'It runs all the tests in a project'
55
+ option :parallel,
56
+ type: :boolean, required: false, desc: 'It runs the tests in parallel', aliases: '-p'
57
+ option :opts,
58
+ type: :array, required: false, desc: 'The options you your parallelization to run with', aliases: '-o'
55
59
 
56
60
  def raid
57
- Utilities.new.run
61
+ if options[:parallel]
62
+ Utilities.new.run(options[:opts])
63
+ else
64
+ Utilities.new.parallel_run(options[:opts])
65
+ end
58
66
  end
59
67
 
60
68
  map '-r' => 'raid'
data/lib/ruby_raider.rb CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  require_relative '../lib/commands/scaffolding_commands'
4
4
 
5
- class RubyRaider
5
+ module RubyRaider
6
6
  def self.start
7
7
  ScaffoldingCommands.start
8
8
  end
@@ -48,12 +48,14 @@ class Utilities
48
48
  overwrite_yaml
49
49
  end
50
50
 
51
- def run
52
- if File.directory? 'spec'
53
- system 'rspec spec/'
54
- else
55
- system 'cucumber features'
56
- end
51
+ def run(opts = nil)
52
+ command = File.directory?('spec') ? 'rspec spec/' : 'cucumber features'
53
+ system "#{command} #{opts}"
54
+ end
55
+
56
+ def parallel_run(opts = nil)
57
+ command = File.directory?('spec') ? 'parallel_rspec spec/' : 'parallel_cucumber features'
58
+ system "#{command} #{opts}"
57
59
  end
58
60
 
59
61
  def overwrite_yaml
data/ruby_raider.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'ruby_raider'
5
- s.version = '0.3.8'
5
+ s.version = '0.3.9'
6
6
  s.summary = 'A gem to make setup and start of UI automation projects easier'
7
7
  s.description = 'This gem has everything you need to start working with test automation'
8
8
  s.authors = ['Agustin Pequeno']
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_raider
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.8
4
+ version: 0.3.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Agustin Pequeno
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-08 00:00:00.000000000 Z
11
+ date: 2022-09-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake