Patrick had been working for the company for three years before he got promoted.
Edward hadn’t been sleeping when you called, he was on the computer.
Had Stacey and Rob been seeing each other long before they broke up?
I had been living at my aunt’s house when I met Jennette.
We hadn’t been walking for an hour when it started to rain.
* NOTE: We can usually use Past Perfect Continuous with Past Simple to say that one action was in progress before another in the past.
Oscar had been watching when the doorbell rang.
(first Oscar was watching then the doorbell rang)
* NOTE: We can use Past Perfect Continuous(Nick had been buying) to focus more on the action
and we can use Past Perfect Simple (Nick had bought) to focus more on the result.
Compare the following:
Nick had been buying property in London a year before we moved there. (Nick bought several properties)
Nick had bought property in London a year before we moved there. (Nick bought a property)