Is it unfair for paper circumstances to play a role in the review of the paper? Let me say beforehand that this question does not refer to scientific correctness and treats it as undisputed, i.e. the paper is assumed correct in the sense that it clearly states a valid purpose, has an adequate literature review, the theory and methods are scientifically sound.

After a brief introspective, it came to me that I often take into the account under what circumstances a paper was written when assessing the scope / prestige of the venue it is to be published at. This usually includes funding, if any, seniority and number of the authors. 

On the one hand, I find it unfair to expect the same scale of experimental devotion from a student-mentor author pair from a developing country with no or relatively little funding as from a research group with multiple grants from a developed country. Given the relevance of the contribution, the first group shouldn't be rejected on the grounds that they don't have a comparable abundance of resources. Also, they shouldn't be discouraged as they managed to make a difference without those resources. And, after all, we do this kind of expectation management in other aspects of life, e.g. one doesn't fail a student because they wrote the assignment in a free text editor, because they can't afford MS Word.

As a concrete example, I once saw another reviewer comment that they would like to see a more significant average deviation on the graphs. This requirement would've required the authors to run tens of multi-hour simulations on a cloud cluster consisting of ~50 high-end instances, each billed by the hour, and it is also rather irrelevant to the proof or the contribution itself. The two authors received a government grant which translated to roughly $1200 for this research at an university that doesn't have subsidies with the cloud provider.

On the other hand, this is clearly a bias. Augmented additionally by the fact that it is not possible to implement during a double-blind review. Also, somewhere in there is an argument how practices to include low-cost research would result in research funding being gradually cut in some way or the other.

So, my question is the dilemma whether it is unfair to let capabilities outside of a research group's direct influence contribute to the review of their paper (again, only once the contribution is established)?

My field is computer science, so, while not strictly pen-and-paper, few resources are needed, relative to other fields, e.g. experimental physics, bio-medicine, etc., to do meaningful research.
No, your review should not change based on knowledge of the authors' circumstances. Your role is to give the editor an objective assessment of the strengths and weaknesses of the author's submitted manuscript. However, you can still help less advantaged authors. Write your review to focus on the strengths and weaknesses of their work, and leave the authors to choose how they wish to address these.

To take your example: suppose that the authors have developed a new algorithm for X, which you consider to be a worthwhile contribution to the field. However, they go on to claim that their algorithm outperforms the current standard, based on only one test-case.

An unhelpful reviewer might write:
"This paper has potential, but it cannot be accepted unless the authors run more test-cases". A more helpful review would be: "The algorithm in this paper appears to be a useful contribution, and it is deserving of publication. However, I do not feel the authors currently have sufficient evidence to support their unqualified claims regarding performance, and this should be addressed before acceptance."

By doing this, you leave the authors with a choice: they can either run more experiments, or they can put caveats around their discussion of performance. (Of course, you should only do this if you feel the paper is publishable in such a form.) A wealthy research group will likely choose the former option, a less well-off one might settle for the latter. However, both have been held to the same standard of scientific correctness.