File tree 6 files changed +42
-66
lines changed
6 files changed +42
-66
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ Class {
10
10
11
11
{
12
12
#category : #running ,
13
- #' squeak_changestamp' : ' TL 7/12/2024 16:18 '
13
+ #' squeak_changestamp' : ' TL 7/12/2024 16:45 '
14
14
}
15
15
SPOCTestApiNext >> setUp [
16
16
@@ -33,14 +33,15 @@ SPOCTestApiNext >> testApiNextExecute [
33
33
34
34
{
35
35
#category : #testing ,
36
- #' squeak_changestamp' : ' TL 6/24 /2024 02:08 '
36
+ #' squeak_changestamp' : ' TL 7/12 /2024 16:35 '
37
37
}
38
38
SPOCTestApiNext >> testSkipToNextOn [
39
39
40
40
| oldPlaybackState newPlaybackState |
41
41
oldPlaybackState := self getPlaybackState.
42
42
self apiEndpoint skipToNextOn: oldPlaybackState device id.
43
+ (Delay forSeconds: 0.6 ) wait.
43
44
newPlaybackState := self getPlaybackState.
44
- " self assert: newPlaybackState track id ~= oldPlaybackState track id."
45
+ self assert: newPlaybackState track id ~= oldPlaybackState track id.
45
46
self assert: newPlaybackState isPlaying
46
47
]
Original file line number Diff line number Diff line change @@ -37,10 +37,11 @@ SPOCTestApiPause >> testApiPauseExecute [
37
37
38
38
{
39
39
#category : #testing ,
40
- #' squeak_changestamp' : ' TL 6/24 /2024 01:53 '
40
+ #' squeak_changestamp' : ' TL 7/12 /2024 16:39 '
41
41
}
42
42
SPOCTestApiPause >> testPauseOn [
43
43
44
44
self apiEndpoint pauseOn: self getPlaybackState device id.
45
+ (Delay forSeconds: 0.6 ) wait.
45
46
self assert: self getPlaybackState isPlaying not
46
47
]
Original file line number Diff line number Diff line change @@ -80,3 +80,36 @@ SPOCTestApiPlay >> testApiPlayTrackwithPlaylistExecute [
80
80
res := self apiEndpoint execute: dict.
81
81
self assert: res response code = 204
82
82
]
83
+
84
+ {
85
+ #category : #testing ,
86
+ #' squeak_changestamp' : ' TL 7/12/2024 16:40'
87
+ }
88
+ SPOCTestApiPlay >> testPlayTrackOn [
89
+
90
+ | playbackState |
91
+ self apiEndpoint playTrack: ' 4PTG3Z6ehGkBFwjybzWkR8' on: self getPlaybackState device id.
92
+ (Delay forSeconds: 0.6 ) wait.
93
+ playbackState := self getPlaybackState.
94
+ self assert: playbackState track id = ' 4PTG3Z6ehGkBFwjybzWkR8' .
95
+ self assert: playbackState isPlaying
96
+
97
+ ]
98
+
99
+ {
100
+ #category : #testing ,
101
+ #' squeak_changestamp' : ' TL 7/12/2024 16:41'
102
+ }
103
+ SPOCTestApiPlay >> testPlayTrackWithAlbumOn [
104
+
105
+ | playbackState |
106
+ self apiEndpoint playTrack: ' 4PTG3Z6ehGkBFwjybzWkR8'
107
+ withAlbum: ' 6eUW0wxWtzkFdaEFsTJto6'
108
+ on: self getPlaybackState device id.
109
+ (Delay forSeconds: 0.6 ) wait.
110
+ playbackState := self getPlaybackState.
111
+ self assert: playbackState track id = ' 4PTG3Z6ehGkBFwjybzWkR8' .
112
+ self assert: playbackState track album id = ' 6eUW0wxWtzkFdaEFsTJto6' .
113
+ self assert: playbackState isPlaying
114
+
115
+ ]
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ Class {
10
10
11
11
{
12
12
#category : #running ,
13
- #' squeak_changestamp' : ' TL 6/24 /2024 03:21 '
13
+ #' squeak_changestamp' : ' TL 7/12 /2024 16:45 '
14
14
}
15
15
SPOCTestApiPrevious >> setUp [
16
16
Original file line number Diff line number Diff line change @@ -33,12 +33,13 @@ SPOCTestApiSwitchDevice >> testApiSwitchDeviceExecute [
33
33
34
34
{
35
35
#category : #testing ,
36
- #' squeak_changestamp' : ' TL 6/24 /2024 02:05 '
36
+ #' squeak_changestamp' : ' TL 7/12 /2024 16:39 '
37
37
}
38
38
SPOCTestApiSwitchDevice >> testSwitchDeviceTo [
39
39
40
40
| newDeviceID |
41
41
newDeviceID := self getPlaybackState device id.
42
42
self apiEndpoint switchDeviceTo: newDeviceID.
43
+ (Delay forSeconds: 0.6 ) wait.
43
44
self assert: self getPlaybackState device id = newDeviceID
44
45
]
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments