The Bavarian giants recovered from their Champions League humiliation with a win over Hamburg and Guardiola feels it sets them up perfectly for their meeting with BVB
The champions went into the fixture at the Imtech Arena on the back of a 5-0 aggregate Champions League semi-final humiliation at the hands of Real Madrid, thus losing the chance to retain their European crown.
Real hammered Bayern 4-0 at Allianz Arena on Tuesday, with Guardiola and his football philosophy coming under intense scrutiny, but Bavarian side bounced back comfortably in Hamburg.
Mario Gotze notched twice and the visitors' other goals came from Thomas Muller and Claudio Pizarro, with the latter burying an audacious overhead kick.
Hamburg midfielder Hakan Calhanoglu pulled one back with the score at 3-0, but Bayern's quality shone through and Guardiola believes his side produced a battling display.
"We fought our way into the match," the former Barcelona boss said.
"The win was good for our rhythm in the preparation for the DFB-Pokal final [against Borussia Dortmund] in Berlin."
With Hamburg desperately searching for goals in order to keep their hopes of Bundesliga survival alive, Arjen Robben believes Bayern made the most of having more space in the second half.
He said: "In the first half we did quite well, but in the second we had slightly more room which we used well.