Tested console code.