The elastocaloric effect in the vicinity of the martensitic transition of a Cu-Zn-Al single crystal has been studied by inducing the transition by strain or stress measurements. While transition trajectories show significant differences, the entropy change associated with the whole transformation (DeltaS_(t)) is coincident in both kinds of experiments since entropy production is small compared to DeltaS_(t). The values agree with estimations based on the Clausius-Clapeyron equation. The possibility of using these materials for mechanical refrigeration is also discussed.