Performance tests of boron-coated straw detectors with thermal and cold neutron beams