Unknown colormap names should fall back to the default ("grayC").
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(inout) | :: | id | |||
| integer, | intent(inout) | :: | nfail |
subroutine test_040(id, nfail) use forcolormap, only: Colormap, wp integer, intent(inout) :: id, nfail character(len=*), parameter :: name = "Colormap%set: invalid name falls back to grayC" logical :: ok type(Colormap) :: cm call cm%set("definitely_not_a_map", 0.0_wp, 1.0_wp) ok = (trim(cm%get_name()) == "grayC") call report_test(name, ok, id, nfail) end subroutine test_040