Search in sources :

Example 1 with DefaultSettingsWriter

use of org.apache.maven.settings.io.DefaultSettingsWriter in project karaf by apache.

the class SettingsTest method readAndWriteSettings.

@Test
public void readAndWriteSettings() throws IOException {
    Settings settings = new Settings();
    Server s = new Server();
    s.setId("id");
    s.setUsername("admin");
    s.setPassword("admin");
    settings.getServers().add(s);
    new DefaultSettingsWriter().write(System.out, null, settings);
}
Also used : Server(org.apache.maven.settings.Server) DefaultSettingsWriter(org.apache.maven.settings.io.DefaultSettingsWriter) Settings(org.apache.maven.settings.Settings) Test(org.junit.Test)

Aggregations

Server (org.apache.maven.settings.Server)1 Settings (org.apache.maven.settings.Settings)1 DefaultSettingsWriter (org.apache.maven.settings.io.DefaultSettingsWriter)1 Test (org.junit.Test)1