@@ -6,10 +6,10 @@ import com.adamratzman.spotify.api
6
6
import com.adamratzman.spotify.getEnvironmentVariable
7
7
import com.adamratzman.spotify.spotifyAppApi
8
8
import com.adamratzman.spotify.spotifyClientApi
9
- import kotlin.test.assertFailsWith
10
9
import kotlinx.coroutines.GlobalScope
11
10
import org.spekframework.spek2.Spek
12
11
import org.spekframework.spek2.style.specification.describe
12
+ import kotlin.test.assertFailsWith
13
13
14
14
class UtilityTests : Spek ({
15
15
describe("Utility tests") {
@@ -22,7 +22,7 @@ class UtilityTests : Spek({
22
22
assertFailsWith<IllegalArgumentException > {
23
23
spotifyClientApi {
24
24
credentials {
25
- clientId = getEnvironmentVariable("clientId ")
25
+ clientId = getEnvironmentVariable("SPOTIFY_CLIENT_ID ")
26
26
}
27
27
}.build()
28
28
}
@@ -34,8 +34,8 @@ class UtilityTests : Spek({
34
34
assertFailsWith<IllegalArgumentException > {
35
35
spotifyClientApi {
36
36
credentials {
37
- clientId = getEnvironmentVariable("clientId ")
38
- clientSecret = getEnvironmentVariable("clientSecret ")
37
+ clientId = getEnvironmentVariable("SPOTIFY_CLIENT_ID ")
38
+ clientSecret = getEnvironmentVariable("SPOTIFY_CLIENT_SECRET ")
39
39
}
40
40
}.build()
41
41
}
@@ -45,8 +45,8 @@ class UtilityTests : Spek({
45
45
it("App API valid parameters") {
46
46
val api = spotifyAppApi {
47
47
credentials {
48
- clientId = getEnvironmentVariable("clientId ")
49
- clientSecret = getEnvironmentVariable("clientSecret ")
48
+ clientId = getEnvironmentVariable("SPOTIFY_CLIENT_ID ")
49
+ clientSecret = getEnvironmentVariable("SPOTIFY_CLIENT_SECRET ")
50
50
}
51
51
}
52
52
api.build()
@@ -56,8 +56,8 @@ class UtilityTests : Spek({
56
56
it("Refresh on invalid token") {
57
57
val api = spotifyAppApi {
58
58
credentials {
59
- clientId = getEnvironmentVariable("clientId ")
60
- clientSecret = getEnvironmentVariable("clientSecret ")
59
+ clientId = getEnvironmentVariable("SPOTIFY_CLIENT_ID ")
60
+ clientSecret = getEnvironmentVariable("SPOTIFY_CLIENT_SECRET ")
61
61
}
62
62
}.build()
63
63
}
0 commit comments