append_html_chartopts: wasn't using the function's digits arg
add tests of chartOpts -> json