Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
陈曦
sub2api
Commits
269c7a06
"frontend/src/api/vscode:/vscode.git/clone" did not exist on "ad80606a4483ac9fb11f9ccc76ff09b3590fc627"
Commit
269c7a06
authored
Apr 09, 2026
by
IanShaw027
Browse files
fix(test): restore integration expectations
parent
b6946e78
Changes
2
Show whitespace changes
Inline
Side-by-side
backend/internal/repository/group_repo.go
View file @
269c7a06
...
...
@@ -43,6 +43,7 @@ func (r *groupRepository) Create(ctx context.Context, groupIn *service.Group) er
SetDescription
(
groupIn
.
Description
)
.
SetPlatform
(
groupIn
.
Platform
)
.
SetRateMultiplier
(
groupIn
.
RateMultiplier
)
.
SetSortOrder
(
groupIn
.
SortOrder
)
.
SetIsExclusive
(
groupIn
.
IsExclusive
)
.
SetStatus
(
groupIn
.
Status
)
.
SetSubscriptionType
(
groupIn
.
SubscriptionType
)
.
...
...
backend/internal/repository/usage_log_repo_request_type_test.go
View file @
269c7a06
...
...
@@ -330,6 +330,15 @@ func TestUsageLogRepositoryGetStatsWithFiltersRequestTypePriority(t *testing.T)
"total_account_cost"
,
"avg_duration_ms"
,
})
.
AddRow
(
int64
(
1
),
int64
(
2
),
int64
(
3
),
int64
(
4
),
1.2
,
1.0
,
1.2
,
20.0
))
mock
.
ExpectQuery
(
"SELECT COALESCE
\\
(NULLIF
\\
(TRIM
\\
(inbound_endpoint
\\
), ''
\\
), 'unknown'
\\
) AS endpoint"
)
.
WithArgs
(
sqlmock
.
AnyArg
(),
sqlmock
.
AnyArg
(),
requestType
)
.
WillReturnRows
(
sqlmock
.
NewRows
([]
string
{
"endpoint"
,
"requests"
,
"total_tokens"
,
"cost"
,
"actual_cost"
}))
mock
.
ExpectQuery
(
"SELECT COALESCE
\\
(NULLIF
\\
(TRIM
\\
(upstream_endpoint
\\
), ''
\\
), 'unknown'
\\
) AS endpoint"
)
.
WithArgs
(
sqlmock
.
AnyArg
(),
sqlmock
.
AnyArg
(),
requestType
)
.
WillReturnRows
(
sqlmock
.
NewRows
([]
string
{
"endpoint"
,
"requests"
,
"total_tokens"
,
"cost"
,
"actual_cost"
}))
mock
.
ExpectQuery
(
"SELECT CONCAT
\\
("
)
.
WithArgs
(
sqlmock
.
AnyArg
(),
sqlmock
.
AnyArg
(),
requestType
)
.
WillReturnRows
(
sqlmock
.
NewRows
([]
string
{
"endpoint"
,
"requests"
,
"total_tokens"
,
"cost"
,
"actual_cost"
}))
stats
,
err
:=
repo
.
GetStatsWithFilters
(
context
.
Background
(),
filters
)
require
.
NoError
(
t
,
err
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment