Working avg block with test