Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
80ee9b5e
Unverified
Commit
80ee9b5e
authored
Jul 21, 2024
by
Jeffrey Morgan
Committed by
GitHub
Jul 21, 2024
Browse files
Remove out of space test temporarily (#5825)
parent
5534f2cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
37 deletions
+0
-37
server/sched_test.go
server/sched_test.go
+0
-37
No files found.
server/sched_test.go
View file @
80ee9b5e
...
...
@@ -7,7 +7,6 @@ import (
"fmt"
"log/slog"
"os"
"runtime"
"testing"
"time"
...
...
@@ -356,42 +355,6 @@ func TestRequestsMultipleLoadedModels(t *testing.T) {
s
.
loadedMu
.
Unlock
()
}
func
TestRequestsModelTooBigForSystem
(
t
*
testing
.
T
)
{
ctx
,
done
:=
context
.
WithTimeout
(
context
.
Background
(),
500
*
time
.
Millisecond
)
defer
done
()
s
:=
InitScheduler
(
ctx
)
s
.
getGpuFn
=
func
()
gpu
.
GpuInfoList
{
g
:=
gpu
.
GpuInfo
{
Library
:
"metal"
}
g
.
TotalMemory
=
4
*
format
.
MebiByte
g
.
FreeMemory
=
3
*
format
.
MebiByte
return
[]
gpu
.
GpuInfo
{
g
}
}
s
.
getCpuFn
=
func
()
gpu
.
GpuInfoList
{
g
:=
gpu
.
GpuInfo
{
Library
:
"cpu"
}
g
.
TotalMemory
=
4
*
format
.
MebiByte
g
.
FreeMemory
=
2
*
format
.
MebiByte
return
[]
gpu
.
GpuInfo
{
g
}
}
a
:=
newScenarioRequest
(
t
,
ctx
,
"ollama-model-1"
,
10
,
&
api
.
Duration
{
Duration
:
5
*
time
.
Millisecond
})
s
.
newServerFn
=
a
.
newServer
slog
.
Info
(
"a"
)
s
.
pendingReqCh
<-
a
.
req
require
.
Len
(
t
,
s
.
pendingReqCh
,
1
)
s
.
Run
(
ctx
)
select
{
case
<-
a
.
req
.
successCh
:
if
runtime
.
GOOS
==
"linux"
{
t
.
Fatal
(
"request should have been rejected with out of space"
)
}
// else - Darwin and Windows don't reject right now
case
err
:=
<-
a
.
req
.
errCh
:
require
.
Contains
(
t
,
err
.
Error
(),
"too large"
)
case
<-
ctx
.
Done
()
:
t
.
Fatal
(
"timeout"
)
}
}
func
TestGetRunner
(
t
*
testing
.
T
)
{
ctx
,
done
:=
context
.
WithTimeout
(
context
.
Background
(),
100
*
time
.
Millisecond
)
defer
done
()
...
...
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