Such a town may enter upon any lands for the purpose of making surveys, test pits and borings, and make take or otherwise acquire the right to occupy temporarily any lands necessary for the construction of any work or for any other purpose authorized by said sections thirty-nine A to thirty-nine E, inclusive.
Mass. Gen. Laws ch. 40, § 39D