The response of a two-dimensional liquid foam to a localized air injection is investigated experimentally and theoretically. The experiments show a rich phenomenology, with two essentially distinct behaviours, depending on the injection conditions. At low flux, the injected air forms a central bubble that grows inside the foam and induces plastic rearrangements, without film rupture. This ‘pure swelling’ regime is reminiscent of ductile fracture. In this regime, the central bubble shows fingering patterns beyond a certain velocity. The dependence among the swelling rate, the injection overpressure and the other control parameters, namely cell gap, bubble size and foam area, is captured by a simple balance between the pressure drop and bubble/wall friction under a radial assumption. Fingering is successfully modelled by the linear stability analysis of an azimuthal perturbation of the radial model; yield stress becomes an important parameter to determine the finger width. At high injection rate, films are broken and narrow cracks form rapidly through the foam, reminiscent of brittle fracture. Criteria for the transition between ductile and brittle behaviours are investigated, both at the local and global scales.