The words used to convey the notion of global testing (tou peirasmou [the testing] and peirasai [to test]) are somewhat ambivalent in meaning. They can refer to temptation (as in an enticement), or to trial (as in an assaying pressure), or to both at the same time. The use of the definite article (tou) is supportive in understanding this phrase as referring to a specific testing or temptation, rather than to testing or temptation in general; i.e. the trial. What is in mind in this message, it seems to me, is a singular kind of testing, the scope and nature of which is such that it will leave no doubt that it is occurring when it does occur.
The test will come upon all the inhabited earth to try those that dwell there. Whereas it is possible to see this as an idiomatic reference to the Roman Empire, I see this more along the lines of a Hebraism (e.g. Exodus 8:21) or just straightforwardly referring to the entire world (as does the word's usage in Acts 17:31 or Hebrews 1:6). The inclusivity of the statement means that anyone on earth at that time will experience the trial, at least in some fashion. One would have to not be living on earth to be kept [out] from such a trial, which I think is the best reading of the promise contained: "I also will keep you from the hour of testing..."
Whereas Chapter 7 of the Apocalypse (and Chapter 12 too) does demonstrate that it is possible to live through the trial on earth protected by God in the midst of it, it also reveals (as does Chapter 12) that for the largest proportion of believers, escape means removal from the scene. 1 Thessalonians 4:15-17 describes the escape in as great a detail as we have in all of scripture. Taken together the picture clarifies. A trial, so significant and singular in nature as to be unmistakable, will come upon the entire earth, but those believers, Philadelphian in character, will be kept from that trial by God taking them out from the earth. Rapture!