@@ -14,7 +14,7 @@ process.env["RUNNER_TOOL_CACHE"] = toolDir;
14
14
import * as installer from "../src/installer" ;
15
15
16
16
describe ( "installer tests" , ( ) => {
17
- beforeEach ( async function ( ) {
17
+ beforeEach ( async function ( ) {
18
18
await io . rmRF ( toolDir ) ;
19
19
await io . rmRF ( tempDir ) ;
20
20
await io . mkdirP ( toolDir ) ;
@@ -31,7 +31,7 @@ describe("installer tests", () => {
31
31
} ) ;
32
32
33
33
it ( "Downloads version of protoc if no matching version is installed" , async ( ) => {
34
- await installer . getProtoc ( "3.9.0" , true , "" ) ;
34
+ await installer . getProtoc ( "3.9.0" , true , process . env [ "GITHUB_TOKEN" ] ) ;
35
35
const protocDir = path . join ( toolDir , "protoc" , "3.9.0" , os . arch ( ) ) ;
36
36
37
37
expect ( fs . existsSync ( `${ protocDir } .complete` ) ) . toBe ( true ) ;
@@ -58,7 +58,7 @@ describe("installer tests", () => {
58
58
} ) ;
59
59
60
60
it ( "Gets the latest 3.7.x version of protoc using 3.7 and no matching version is installed" , async ( ) => {
61
- await installer . getProtoc ( "3.7" , true , "" ) ;
61
+ await installer . getProtoc ( "3.7" , true , process . env [ "GITHUB_TOKEN" ] ) ;
62
62
const protocDir = path . join ( toolDir , "protoc" , "3.7.1" , os . arch ( ) ) ;
63
63
64
64
expect ( fs . existsSync ( `${ protocDir } .complete` ) ) . toBe ( true ) ;
@@ -72,7 +72,7 @@ describe("installer tests", () => {
72
72
} , 100000 ) ;
73
73
74
74
it ( "Gets latest version of protoc using 3.x and no matching version is installed" , async ( ) => {
75
- await installer . getProtoc ( "3.x" , true , "" ) ;
75
+ await installer . getProtoc ( "3.x" , true , process . env [ "GITHUB_TOKEN" ] ) ;
76
76
const protocDir = path . join ( toolDir , "protoc" , "3.9.1" , os . arch ( ) ) ;
77
77
78
78
expect ( fs . existsSync ( `${ protocDir } .complete` ) ) . toBe ( true ) ;
0 commit comments