Fixed the adding of a profiles with durations, updated tests.