File tree Expand file tree Collapse file tree 2 files changed +483
-154
lines changed
terraform-aws-github-runner/modules/runners/lambdas/runners/src/scale-runners Expand file tree Collapse file tree 2 files changed +483
-154
lines changed Original file line number Diff line number Diff line change @@ -44,19 +44,48 @@ describe('./metrics', () => {
4444 m . runRepo ( { owner : 'o' , repo : 'r' } ) ;
4545 m . runRepo ( { owner : 'o' , repo : 'r' } ) ;
4646 m . runRepo ( { owner : 'o' , repo : 'r' } ) ;
47+ m . runRepo ( { owner : 'o' , repo : 'r1' } ) ;
48+ m . runRepo ( { owner : 'o' , repo : 'r1' } ) ;
4749 await m . sendMetrics ( ) ;
4850
4951 expect ( mockCloudWatch . putMetricData ) . toBeCalledWith ( {
5052 MetricData : [
5153 {
5254 Counts : [ 1 ] ,
53- MetricName : 'run.o.r.process' ,
55+ Dimensions : [
56+ {
57+ Name : 'Owner' ,
58+ Value : 'o' ,
59+ } ,
60+ {
61+ Name : 'Repo' ,
62+ Value : 'r' ,
63+ } ,
64+ ] ,
65+ MetricName : 'run.process' ,
5466 Timestamp : spyDate . mock . instances [ 0 ] ,
5567 Unit : 'Count' ,
5668 Values : [ 3 ] ,
5769 } ,
70+ {
71+ Counts : [ 1 ] ,
72+ Dimensions : [
73+ {
74+ Name : 'Owner' ,
75+ Value : 'o' ,
76+ } ,
77+ {
78+ Name : 'Repo' ,
79+ Value : 'r1' ,
80+ } ,
81+ ] ,
82+ MetricName : 'run.process' ,
83+ Timestamp : spyDate . mock . instances [ 0 ] ,
84+ Unit : 'Count' ,
85+ Values : [ 2 ] ,
86+ } ,
5887 ] ,
59- Namespace : 'environ-scaleUp' ,
88+ Namespace : 'environ-scaleUp-dim ' ,
6089 } ) ;
6190 } ) ;
6291
@@ -107,7 +136,7 @@ describe('./metrics', () => {
107136 Values : [ 1 ] ,
108137 } ,
109138 ] ,
110- Namespace : 'environ-scaleUp' ,
139+ Namespace : 'environ-scaleUp-dim ' ,
111140 } ) ;
112141 } ) ;
113142
You can’t perform that action at this time.
0 commit comments