All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.thucydides.core.steps.StepArgumentWriter Maven / Gradle / Ivy

There is a newer version: 4.2.1
Show newest version
package net.thucydides.core.steps;

import org.apache.commons.lang3.ArrayUtils;

public class StepArgumentWriter {

    public static String readableFormOf(Object arg) {
        if (arg == null) {
            return "";
        } else if (arg.getClass().isArray()) {
            return ArrayUtils.toString(arg);
        } else {
            try {
                return arg.toString();
            } catch (Throwable e) {
                return "<" + arg.getClass().getName() + ">";
            }
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy