added fixed test and minor tweaks to fixed functions