@@ -0,0 +1,2571 @@
+package hu.supercluster.overpasser.library.query;%0A%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport hu.supercluster.overpasser.library.output.OutputModificator;%0Aimport hu.supercluster.overpasser.library.output.OutputOrder;%0Aimport hu.supercluster.overpasser.library.output.OutputVerbosity;%0A%0Aimport static hu.supercluster.overpasser.library.output.OutputFormat.*;%0Aimport static org.hamcrest.CoreMatchers.isA;%0Aimport static org.junit.Assert.*;%0A%0Apublic class OverpassQueryTest %7B%0A%0A    private OverpassQuery query;%0A%0A    @Before%0A    public void setUp() throws Exception %7B%0A        query = new OverpassQuery();%0A    %7D%0A%0A    @Test%0A    public void testBuild() throws Exception %7B%0A        final String s = query.build();%0A%0A        assertEquals(%22;%22, s);%0A    %7D%0A%0A    @Test%0A    public void testFormat() throws Exception %7B%0A        query.format(JSON);%0A%0A        assertEquals(%22%5B%5C%22out%5C%22:%5C%22json%5C%22%5D;%22, query.build());%0A    %7D%0A%0A    @Test%0A    public void testTimeout() throws Exception %7B%0A        query.timeout(30);%0A%0A        assertEquals(%22%5B%5C%22timeout%5C%22:%5C%2230%5C%22%5D;%22, query.build());%0A    %7D%0A%0A    @Test%0A    public void testFilterQuery() throws Exception %7B%0A        OverpassFilterQuery filterQuery = query.filterQuery();%0A%0A        assertThat(filterQuery, isA(OverpassFilterQuery.class));%0A    %7D%0A%0A    @Test%0A    public void testOutputWithDefaultArgs() throws Exception %7B%0A        query.output(100);%0A%0A        assertEquals(%22; out body center qt 100;%22, query.build());%0A    %7D%0A%0A    @Test%0A    public void testOutputWithCustomArgs() throws Exception %7B%0A        query.output(OutputVerbosity.META, OutputModificator.GEOM, OutputOrder.ASC, 100);%0A%0A        assertEquals(%22; out meta geom asc 100;%22, query.build());%0A    %7D%0A%0A    @Test%0A    public void testExample1() throws Exception %7B%0A        String result = new OverpassQuery()%0A                .format(JSON)%0A                .timeout(30)%0A                .filterQuery()%0A                .node()%0A                .amenity(%22parking%22)%0A                .notEquals(%22access%22, %22private%22)%0A                .boundingBox(%0A                        47.48047027491862, 19.039797484874725,%0A                        47.51331674014172, 19.07404761761427%0A                )%0A                .end()%0A                .output(OutputVerbosity.BODY, OutputModificator.CENTER, OutputOrder.QT, 100)%0A                .build()%0A        ;%0A%0A        String expected = %22%5B%5C%22out%5C%22:%5C%22json%5C%22%5D%5B%5C%22timeout%5C%22:%5C%2230%5C%22%5D; (node%5B%5C%22amenity%5C%22=%5C%22parking%5C%22%5D%5B%5C%22access%5C%22!=%5C%22private%5C%22%5D(47.48047027491862,19.039797484874725,47.51331674014172,19.07404761761427);%3C;); out body center qt 100;%22;%0A%0A        assertEquals(expected, result);%0A    %7D%0A%7D

Add OverpassQueryTest