Skip to content

Commit

Permalink
Update tests for core routines
Browse files Browse the repository at this point in the history
  • Loading branch information
amontoison committed Aug 25, 2024
1 parent 410d6bc commit 49c0f03
Show file tree
Hide file tree
Showing 2 changed files with 100 additions and 100 deletions.
28 changes: 14 additions & 14 deletions test/coverage.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,35 +3,35 @@ function coverage_increase(nlp::CUTEstModel{T}) where {T}
status = Cint[0]
n, m = nlp.meta.nvar, nlp.meta.ncon
pname = Vector{Cchar}(undef, 10)
probname(T, status, pname)
CUTEst.probname(T, status, pname)
vname = Matrix{Cchar}(undef, 10, n)
varnames(T, status, Cint[n], vname)
CUTEst.varnames(T, status, Cint[n], vname)
if m == 0
unames(T, status, Cint[n], pname, vname)
CUTEst.unames(T, status, Cint[n], pname, vname)
calls = Vector{T}(undef, 4)
time = Vector{T}(undef, 4)
ureport(T, status, calls, time)
CUTEst.ureport(T, status, calls, time)
else
cname = Matrix{Cchar}(undef, 10, m)
connames(T, status, Cint[m], cname)
cnames(T, status, Cint[n], Cint[m], pname, vname, cname)
CUTEst.connames(T, status, Cint[m], cname)
CUTEst.cnames(T, status, Cint[n], Cint[m], pname, vname, cname)
calls = Vector{T}(undef, 7)
time = Vector{T}(undef, 4)
creport(T, status, calls, time)
CUTEst.creport(T, status, calls, time)
nvo, nvc, ec, lc = Cint[0], Cint[0], Cint[0], Cint[0]
cstats(T, status, nvo, nvc, ec, lc)
CUTEst.cstats(T, status, nvo, nvc, ec, lc)

lchp = Cint[0]
cdimchp(T, status, lchp)
CUTEst.cdimchp(T, status, lchp)
chp_ind, chp_ptr = Vector{Cint}(undef, lchp[1]), Vector{Cint}(undef, m + 1)
cchprodsp(T, status, Cint[m], lchp, chp_ind, chp_ptr)
CUTEst.cchprodsp(T, status, Cint[m], lchp, chp_ind, chp_ptr)
lj, nnzj = Cint[0], Cint[0]
cdimsj(T, status, lj)
CUTEst.cdimsj(T, status, lj)
j_var, j_fun = Vector{Cint}(undef, lj[1]), Vector{Cint}(undef, lj[1])
csgrp(T, status, Cint[n], nnzj, lj, j_var, j_fun)
CUTEst.csgrp(T, status, Cint[n], nnzj, lj, j_var, j_fun)
lh, nnzh = Cint[0], Cint[0]
cdimsh(T, status, lh)
CUTEst.cdimsh(T, status, lh)
h_row, h_col = Vector{Cint}(undef, lh[1]), Vector{Cint}(undef, lh[1])
csgrshp(T, status, Cint[n], nnzj, lj, j_var, j_fun, nnzh, lh, h_row, h_col)
CUTEst.csgrshp(T, status, Cint[n], nnzj, lj, j_var, j_fun, nnzh, lh, h_row, h_col)
end
end
Loading

0 comments on commit 49c0f03

Please sign in to comment.