calandroid-widget-extension 0.0.2 → 0.0.3

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
  SHA1:
3
- metadata.gz: cde1f524cebde67d65e3eed57f968a774eac67fb
4
- data.tar.gz: e7808a091d5dd562352d614e7c09281b8e78b120
3
+ metadata.gz: 246ee91562962c73a53cea7e56cefa1c6996aa66
4
+ data.tar.gz: 048bb0808f89b8407276bd30a00a8f59295ab99f
5
5
  SHA512:
6
- metadata.gz: f3cf2f6b28aad7ca4e78ad2ca31b2a8840a4e5be8f2cc29455642903cfd185d70b7125d5e434053fdb76f15d61df32fd646976831e9c2a1fe3167cf2b661192b
7
- data.tar.gz: 2e9ed7ca4312b49d3556f914c79a345ebac6893df700d35eb1115d219427fa76df6c687e4f61cce61a30d840ede71667a64b904ad17e8296f1d05bf5a4e6e1b0
6
+ metadata.gz: 12c61d985a03053d6880b94237ca8fb339e291de2b4a972a4ce498a67a98e638bb4d356d89b75d7cc3d3d2295b56ca47d61e87e565efbbec0edbfb15f3a0b96f
7
+ data.tar.gz: cb311c3880e3e52b3c9de0b9911f89e9761370aa90e1c4fdc12d134b70d133525b7dc9c6c7ba89b197fc5dd7262054e44aa6e4665fe8a251b42f16282042a9aa
@@ -1,3 +1,3 @@
1
1
  module CalandroidWidgetExtension
2
- VERSION = '0.0.2'
2
+ VERSION = '0.0.3'
3
3
  end
data/spec/spec_base.rb CHANGED
@@ -11,6 +11,61 @@ class SpecBase < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'Base' do
14
+ classes = [Button, FrameLayout, ImageButton, LinearLayout, ListView, TextView]
15
+ classes.each do |klass|
16
+ describe "#{klass}.class_name" do
17
+ it 'should return class name' do
18
+ klass.class_name.must_equal(klass.to_s)
19
+ end
20
+ end
21
+
22
+ describe "#{klass}.touch and aliases" do
23
+ it 'should call Calabash touch method with correct parameters' do
24
+ klass.touch
25
+ $uiquery.must_equal("#{klass.class_name}")
26
+
27
+ klass.touch(0)
28
+ $uiquery.must_equal("#{klass.class_name} index:0")
29
+
30
+ klass.touch('myId')
31
+ $uiquery.must_equal("#{klass.class_name} marked:'myId'")
32
+
33
+ klass.tap
34
+ $uiquery.must_equal("#{klass.class_name}")
35
+
36
+ klass.tap(0)
37
+ $uiquery.must_equal("#{klass.class_name} index:0")
38
+
39
+ klass.tap('myId')
40
+ $uiquery.must_equal("#{klass.class_name} marked:'myId'")
41
+ end
42
+ end
43
+
44
+ describe "#{klass}.property and aliases" do
45
+ it 'should call Calabash query method with correct parameters' do
46
+ klass.property(:finland)
47
+ $uiquery.must_equal("#{klass.class_name}")
48
+ $args.first.must_equal(:finland)
49
+
50
+ klass.prop(:finland)
51
+ $uiquery.must_equal("#{klass.class_name}")
52
+ $args.first.must_equal(:finland)
53
+
54
+ klass.p(:finland)
55
+ $uiquery.must_equal("#{klass.class_name}")
56
+ $args.first.must_equal(:finland)
57
+ end
58
+ end
59
+
60
+ describe "#{klass}.id" do
61
+ it 'should call Calabash query method with correct parameters' do
62
+ klass.id
63
+ $uiquery.must_equal("#{klass.class_name}")
64
+ $args.first.must_equal(:id)
65
+ end
66
+ end
67
+ end
68
+
14
69
  describe 'Base.raise_if_invalid' do
15
70
  it 'should raise' do
16
71
  proc { Button.text(:symbol) }.must_raise(RuntimeError)
data/spec/spec_button.rb CHANGED
@@ -11,12 +11,6 @@ class SpecButton < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'Button' do
14
- describe 'Button.class_name' do
15
- it 'should return class name' do
16
- Button.class_name.must_equal('Button')
17
- end
18
- end
19
-
20
14
  describe 'Button.text' do
21
15
  it 'should call Calabash query method with correct parameters' do
22
16
  $stub_query_response = %w(varkaus oulu kuopio)
@@ -56,51 +50,5 @@ class SpecButton < Minitest::Spec
56
50
  $args.first.must_equal(:selected)
57
51
  end
58
52
  end
59
-
60
- describe 'Button.touch and aliases' do
61
- it 'should call Calabash touch method with correct parameters' do
62
- Button.touch
63
- $uiquery.must_equal("#{Button.class_name}")
64
-
65
- Button.touch(0)
66
- $uiquery.must_equal("#{Button.class_name} index:0")
67
-
68
- Button.touch('myId')
69
- $uiquery.must_equal("#{Button.class_name} marked:'myId'")
70
-
71
- Button.tap
72
- $uiquery.must_equal("#{Button.class_name}")
73
-
74
- Button.tap(0)
75
- $uiquery.must_equal("#{Button.class_name} index:0")
76
-
77
- Button.tap('myId')
78
- $uiquery.must_equal("#{Button.class_name} marked:'myId'")
79
- end
80
- end
81
-
82
- describe 'Button.property and aliases' do
83
- it 'should call Calabash query method with correct parameters' do
84
- Button.property(:finland)
85
- $uiquery.must_equal("#{Button.class_name}")
86
- $args.first.must_equal(:finland)
87
-
88
- Button.prop(:finland)
89
- $uiquery.must_equal("#{Button.class_name}")
90
- $args.first.must_equal(:finland)
91
-
92
- Button.p(:finland)
93
- $uiquery.must_equal("#{Button.class_name}")
94
- $args.first.must_equal(:finland)
95
- end
96
- end
97
-
98
- describe 'Button.id' do
99
- it 'should call Calabash query method with correct parameters' do
100
- Button.id
101
- $uiquery.must_equal("#{Button.class_name}")
102
- $args.first.must_equal(:id)
103
- end
104
- end
105
53
  end
106
54
  end
@@ -11,56 +11,6 @@ class SpecFrameLayout < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'FrameLayout' do
14
- describe 'FrameLayout.class_name' do
15
- it 'should return class name' do
16
- FrameLayout.class_name.must_equal('FrameLayout')
17
- end
18
- end
19
-
20
- describe 'FrameLayout.touch and aliases' do
21
- it 'should call Calabash touch method with correct parameters' do
22
- FrameLayout.touch
23
- $uiquery.must_equal("#{FrameLayout.class_name}")
24
-
25
- FrameLayout.touch(0)
26
- $uiquery.must_equal("#{FrameLayout.class_name} index:0")
27
-
28
- FrameLayout.touch('myId')
29
- $uiquery.must_equal("#{FrameLayout.class_name} marked:'myId'")
30
-
31
- FrameLayout.tap
32
- $uiquery.must_equal("#{FrameLayout.class_name}")
33
-
34
- FrameLayout.tap(0)
35
- $uiquery.must_equal("#{FrameLayout.class_name} index:0")
36
-
37
- FrameLayout.tap('myId')
38
- $uiquery.must_equal("#{FrameLayout.class_name} marked:'myId'")
39
- end
40
- end
41
-
42
- describe 'FrameLayout.property and aliases' do
43
- it 'should call Calabash query method with correct parameters' do
44
- FrameLayout.property(:finland)
45
- $uiquery.must_equal("#{FrameLayout.class_name}")
46
- $args.first.must_equal(:finland)
47
-
48
- FrameLayout.prop(:finland)
49
- $uiquery.must_equal("#{FrameLayout.class_name}")
50
- $args.first.must_equal(:finland)
51
-
52
- FrameLayout.p(:finland)
53
- $uiquery.must_equal("#{FrameLayout.class_name}")
54
- $args.first.must_equal(:finland)
55
- end
56
- end
57
-
58
- describe 'FrameLayout.id' do
59
- it 'should call Calabash query method with correct parameters' do
60
- FrameLayout.id
61
- $uiquery.must_equal("#{FrameLayout.class_name}")
62
- $args.first.must_equal(:id)
63
- end
64
- end
14
+ # Nothing here yet
65
15
  end
66
16
  end
@@ -11,12 +11,6 @@ class SpecImageButton < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'ImageButton' do
14
- describe 'ImageButton.class_name' do
15
- it 'should return class name' do
16
- ImageButton.class_name.must_equal('ImageButton')
17
- end
18
- end
19
-
20
14
  describe 'ImageButton.selected?' do
21
15
  it 'should call Calabash query method with correct parameters' do
22
16
  $stub_query_response = [false, true]
@@ -60,51 +54,5 @@ class SpecImageButton < Minitest::Spec
60
54
  $args.first.must_equal(:activated)
61
55
  end
62
56
  end
63
-
64
- describe 'ImageButton.touch and aliases' do
65
- it 'should call Calabash touch method with correct parameters' do
66
- ImageButton.touch
67
- $uiquery.must_equal("#{ImageButton.class_name}")
68
-
69
- ImageButton.touch(0)
70
- $uiquery.must_equal("#{ImageButton.class_name} index:0")
71
-
72
- ImageButton.touch('myId')
73
- $uiquery.must_equal("#{ImageButton.class_name} marked:'myId'")
74
-
75
- ImageButton.tap
76
- $uiquery.must_equal("#{ImageButton.class_name}")
77
-
78
- ImageButton.tap(0)
79
- $uiquery.must_equal("#{ImageButton.class_name} index:0")
80
-
81
- ImageButton.tap('myId')
82
- $uiquery.must_equal("#{ImageButton.class_name} marked:'myId'")
83
- end
84
- end
85
-
86
- describe 'ImageButton.property and aliases' do
87
- it 'should call Calabash query method with correct parameters' do
88
- ImageButton.property(:finland)
89
- $uiquery.must_equal("#{ImageButton.class_name}")
90
- $args.first.must_equal(:finland)
91
-
92
- ImageButton.prop(:finland)
93
- $uiquery.must_equal("#{ImageButton.class_name}")
94
- $args.first.must_equal(:finland)
95
-
96
- ImageButton.p(:finland)
97
- $uiquery.must_equal("#{ImageButton.class_name}")
98
- $args.first.must_equal(:finland)
99
- end
100
- end
101
-
102
- describe 'ImageButton.id' do
103
- it 'should call Calabash query method with correct parameters' do
104
- ImageButton.id
105
- $uiquery.must_equal("#{ImageButton.class_name}")
106
- $args.first.must_equal(:id)
107
- end
108
- end
109
57
  end
110
58
  end
@@ -11,56 +11,6 @@ class SpecLinearLayout < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'LinearLayout' do
14
- describe 'LinearLayout.class_name' do
15
- it 'should return class name' do
16
- LinearLayout.class_name.must_equal('LinearLayout')
17
- end
18
- end
19
-
20
- describe 'LinearLayout.touch and aliases' do
21
- it 'should call Calabash touch method with correct parameters' do
22
- LinearLayout.touch
23
- $uiquery.must_equal("#{LinearLayout.class_name}")
24
-
25
- LinearLayout.touch(0)
26
- $uiquery.must_equal("#{LinearLayout.class_name} index:0")
27
-
28
- LinearLayout.touch('myId')
29
- $uiquery.must_equal("#{LinearLayout.class_name} marked:'myId'")
30
-
31
- LinearLayout.tap
32
- $uiquery.must_equal("#{LinearLayout.class_name}")
33
-
34
- LinearLayout.tap(0)
35
- $uiquery.must_equal("#{LinearLayout.class_name} index:0")
36
-
37
- LinearLayout.tap('myId')
38
- $uiquery.must_equal("#{LinearLayout.class_name} marked:'myId'")
39
- end
40
- end
41
-
42
- describe 'LinearLayout.property and aliases' do
43
- it 'should call Calabash query method with correct parameters' do
44
- LinearLayout.property(:finland)
45
- $uiquery.must_equal("#{LinearLayout.class_name}")
46
- $args.first.must_equal(:finland)
47
-
48
- LinearLayout.prop(:finland)
49
- $uiquery.must_equal("#{LinearLayout.class_name}")
50
- $args.first.must_equal(:finland)
51
-
52
- LinearLayout.p(:finland)
53
- $uiquery.must_equal("#{LinearLayout.class_name}")
54
- $args.first.must_equal(:finland)
55
- end
56
- end
57
-
58
- describe 'LinearLayout.id' do
59
- it 'should call Calabash query method with correct parameters' do
60
- LinearLayout.id
61
- $uiquery.must_equal("#{LinearLayout.class_name}")
62
- $args.first.must_equal(:id)
63
- end
64
- end
14
+ # Nothing here yet
65
15
  end
66
16
  end
@@ -11,56 +11,6 @@ class SpecListView < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'ListView' do
14
- describe 'ListView.class_name' do
15
- it 'should return class name' do
16
- ListView.class_name.must_equal('ListView')
17
- end
18
- end
19
-
20
- describe 'ListView.touch and aliases' do
21
- it 'should call Calabash touch method with correct parameters' do
22
- ListView.touch
23
- $uiquery.must_equal("#{ListView.class_name}")
24
-
25
- ListView.touch(0)
26
- $uiquery.must_equal("#{ListView.class_name} index:0")
27
-
28
- ListView.touch('myId')
29
- $uiquery.must_equal("#{ListView.class_name} marked:'myId'")
30
-
31
- ListView.tap
32
- $uiquery.must_equal("#{ListView.class_name}")
33
-
34
- ListView.tap(0)
35
- $uiquery.must_equal("#{ListView.class_name} index:0")
36
-
37
- ListView.tap('myId')
38
- $uiquery.must_equal("#{ListView.class_name} marked:'myId'")
39
- end
40
- end
41
-
42
- describe 'ListView.property and aliases' do
43
- it 'should call Calabash query method with correct parameters' do
44
- ListView.property(:finland)
45
- $uiquery.must_equal("#{ListView.class_name}")
46
- $args.first.must_equal(:finland)
47
-
48
- ListView.prop(:finland)
49
- $uiquery.must_equal("#{ListView.class_name}")
50
- $args.first.must_equal(:finland)
51
-
52
- ListView.p(:finland)
53
- $uiquery.must_equal("#{ListView.class_name}")
54
- $args.first.must_equal(:finland)
55
- end
56
- end
57
-
58
- describe 'ListView.id' do
59
- it 'should call Calabash query method with correct parameters' do
60
- ListView.id
61
- $uiquery.must_equal("#{ListView.class_name}")
62
- $args.first.must_equal(:id)
63
- end
64
- end
14
+ # Nothing here yet
65
15
  end
66
16
  end
@@ -11,12 +11,6 @@ class SpecTextView < Minitest::Spec
11
11
  end
12
12
 
13
13
  describe 'TextView' do
14
- describe 'TextView.class_name' do
15
- it 'should return class name' do
16
- TextView.class_name.must_equal('TextView')
17
- end
18
- end
19
-
20
14
  describe 'TextView.text' do
21
15
  it 'should call Calabash query method with correct parameters' do
22
16
  $stub_query_response = %w(varkaus oulu kuopio)
@@ -34,51 +28,5 @@ class SpecTextView < Minitest::Spec
34
28
  $args.first.must_equal(:text)
35
29
  end
36
30
  end
37
-
38
- describe 'TextView.touch and aliases' do
39
- it 'should call Calabash touch method with correct parameters' do
40
- TextView.touch
41
- $uiquery.must_equal("#{TextView.class_name}")
42
-
43
- TextView.touch(0)
44
- $uiquery.must_equal("#{TextView.class_name} index:0")
45
-
46
- TextView.touch('myId')
47
- $uiquery.must_equal("#{TextView.class_name} marked:'myId'")
48
-
49
- TextView.tap
50
- $uiquery.must_equal("#{TextView.class_name}")
51
-
52
- TextView.tap(0)
53
- $uiquery.must_equal("#{TextView.class_name} index:0")
54
-
55
- TextView.tap('myId')
56
- $uiquery.must_equal("#{TextView.class_name} marked:'myId'")
57
- end
58
- end
59
-
60
- describe 'TextView.property and aliases' do
61
- it 'should call Calabash query method with correct parameters' do
62
- TextView.property(:finland)
63
- $uiquery.must_equal("#{TextView.class_name}")
64
- $args.first.must_equal(:finland)
65
-
66
- TextView.prop(:finland)
67
- $uiquery.must_equal("#{TextView.class_name}")
68
- $args.first.must_equal(:finland)
69
-
70
- TextView.p(:finland)
71
- $uiquery.must_equal("#{TextView.class_name}")
72
- $args.first.must_equal(:finland)
73
- end
74
- end
75
-
76
- describe 'TextView.id' do
77
- it 'should call Calabash query method with correct parameters' do
78
- TextView.id
79
- $uiquery.must_equal("#{TextView.class_name}")
80
- $args.first.must_equal(:id)
81
- end
82
- end
83
31
  end
84
32
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: calandroid-widget-extension
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jani Jegoroff