Large-Eddy Simulation is used to study a turbulent boundary layer subject to a space- and time-dependent free-stream pressure gradient. Comparison is made with steady cases with fixed pressure gradients. The adverse pressure gradient is strong enough to cause flow separation. The pressure gradient is prescribed by an oscillating blowing and suction profile at the top boundary. Several cases have been investigated for a range of reduced frequencies k. For the highest k the separation bubble is not as thick as in an equivalent steady case, but its length remains comparable. The phase-averaged field shows that the flow is synchronized with the forcing throughout the domain. However, hysteresis occurs in the near wall region. As the reduced frequency decreases, the extent of the separation bubble in the wall-normal direction increases, but its length is reduced compared with the corresponding steady case. The region of slow-moving fluid generated by the flow reversal is advected downstream, causing a decorrelation between the forcing and the velocity and pressure in this region.