File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,10 @@ def get_description():
148
148
"""
149
149
150
150
151
+ def abspath (astring ):
152
+ return os .path .abspath (astring )
153
+
154
+
151
155
def create_argument_parser (description : str ):
152
156
"""Create and configure the argument parser for the CLI."""
153
157
parser = ArgumentParserWithDefaults (
@@ -222,6 +226,7 @@ def configure_arguments(parser):
222
226
parser .add_argument (
223
227
"--store" ,
224
228
default = CONFIG .store ,
229
+ type = abspath ,
225
230
help = "store AI Models in the specified directory" ,
226
231
)
227
232
parser .add_argument (
Original file line number Diff line number Diff line change @@ -59,4 +59,12 @@ Store | $store
59
59
60
60
}
61
61
62
+ @test " ramalama info --store" {
63
+ randdir=$( random_string 20)
64
+ store=$PWD /${randdir}
65
+ run_ramalama --store ./${randdir} info
66
+ actual=$( echo " $output " | jq -r " .Store" )
67
+ is " $actual " " $store " " Verify relative paths translated to absolute path"
68
+ }
69
+
62
70
# vim: filetype=sh
You can’t perform that action at this time.
0 commit comments