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

liquibase.ui.MockConsoleWrapper Maven / Gradle / Ivy

There is a newer version: 4.29.2
Show newest version
package liquibase.ui;

import java.util.*;

public class MockConsoleWrapper extends ConsoleUIService.ConsoleWrapper {

    final private List responses;

    public MockConsoleWrapper(String... responses) {
        super(null, false);
        this.responses = new ArrayList<>(Arrays.asList(responses));
    }

    @Override
    public boolean supportsInput() {
        return true;
    }

    @Override
    public String readLine() {
        return responses.remove(0);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy