make julia compatible with texttests

This commit is contained in:
Andriamanitra 2023-06-12 16:41:55 +03:00
parent a674623c1c
commit e6445f1782
3 changed files with 16 additions and 2 deletions

View File

@ -78,12 +78,13 @@ function main(; days::Int64=2)
Item("Backstage passes to a TAFKAL80ETC concert", 5, 49), Item("Backstage passes to a TAFKAL80ETC concert", 5, 49),
Item("Conjured Mana Cake", 3, 6), Item("Conjured Mana Cake", 3, 6),
] ]
for day in 1:days for day in 0:days
println("-------- day $day --------") println("-------- day $day --------")
println("name, sellin, quality") println("name, sellIn, quality")
for item in items for item in items
println(item) println(item)
end end
println()
update_quality!(GildedRose(items)) update_quality!(GildedRose(items))
end end
end end

View File

@ -0,0 +1,9 @@
include("gilded_rose.jl")
if length(ARGS) > 0
days = parse(Int64, ARGS[1])
else
days = 2
end
main(days=days)

View File

@ -31,4 +31,8 @@ diff_program:meld
#executable:${TEXTTEST_HOME}/TypeScript/test/golden-master-text-test.js #executable:${TEXTTEST_HOME}/TypeScript/test/golden-master-text-test.js
#interpreter:node #interpreter:node
# Settings for the Julia version
#executable:${TEXTTEST_HOME}/julia/texttest_fixture.jl
#interpreter:julia
filename_convention_scheme:standard filename_convention_scheme:standard