File tree Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI 
2+ 
3+ on :
4+   push :
5+     branches : [ main ] 
6+   pull_request :
7+     branches : [ main ] 
8+ 
9+ jobs :
10+   lint-and-test :
11+     runs-on : ubuntu-latest 
12+ 
13+     strategy :
14+       matrix :
15+         lambda : [collector, external-alerts-webhook] 
16+ 
17+     steps :
18+     - uses : actions/checkout@v4 
19+ 
20+     - name : Setup Node.js 
21+       uses : actions/setup-node@v4 
22+       with :
23+         node-version : ' 18' 
24+         cache : ' yarn' 
25+         cache-dependency-path : ' lambdas/${{ matrix.lambda }}/yarn.lock' 
26+ 
27+     - name : Install dependencies 
28+       run : | 
29+         cd lambdas/${{ matrix.lambda }} 
30+         yarn install --frozen-lockfile 
31+ 
32+ name : Run lint 
33+       run : | 
34+         cd lambdas/${{ matrix.lambda }} 
35+         yarn lint 
36+ 
37+ name : Run format check 
38+       run : | 
39+         cd lambdas/${{ matrix.lambda }} 
40+         yarn format:check 
41+ 
42+ name : Run tests 
43+       run : | 
44+         cd lambdas/${{ matrix.lambda }} 
45+         if [ -f "package.json" ] && grep -q '"test"' package.json; then 
46+           yarn test 
47+         else 
48+           echo "No tests found for ${{ matrix.lambda }}" 
49+         fi 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments