How would we determine how life evolved on other planets?
The first step would be to discover life on some other planet beyond Earth and see if what we have learned so far applies to other worlds.
So far we only have a sample size of life in the universe where n=1, so its very hard to generalize that the principles of biology that work on Earth may also apply on other planets. Having said that, most exo-biologists are starting from the assumption that if life does exist on other worlds it may have arose in a similar process, and under similar conditions, as that on Earth. Also, they assume for now at least that Darwinian evolution might also apply on other planets.
However some biologists feel that this approach may be too narrow and we should be open to the idea that life on other worlds may have evolved out of say, silicon instead of carbon.
Interestingly, some cosmologists have started to propose that the concept of evolution may also apply in some non-biological processes in the universe. For example, some argue that the so called constants of physics may in fact not be constant, but might be evolving over time!