// Path: jres-test/src/main/java/com/blacklocus/jres/BaseJresTest.java
// public class BaseJresTest {
// 
//     @BeforeClass
//     public static void startLocalElasticSearch() {
//         ElasticSearchTestInstance.triggerStaticInit();
//     }
// 
//     /**
//      * Configured to connect to a local ElasticSearch instance created specifically for unit testing
//      */
//     protected Jres jres = new Jres(Suppliers.ofInstance("http://localhost:9201"));
// 
// }
// 
// Path: jres-core/src/main/java/com/blacklocus/jres/request/index/JresCreateIndex.java
// public class JresCreateIndex extends JresJsonRequest<JresAcknowledgedReply> {
// 
//     private final String index;
//     private final Object settings;
// 
//     public JresCreateIndex(String index) {
//         this(index, null);
//     }
// 
//     public JresCreateIndex(String index, String settingsJson) {
//         super(JresAcknowledgedReply.class);
//         this.index = index;
//         this.settings = settingsJson;
//     }
// 
//     @Override
//     public String getHttpMethod() {
//         return HttpPut.METHOD_NAME;
//     }
// 
//     @Override
//     public String getPath() {
//         return index;
//     }
// 
//     @Override
//     public Object getPayload() {
//         return settings;
//     }
// 
// }
// 
// Path: jres-core/src/main/java/com/blacklocus/jres/response/JresBooleanReply.java
// public class JresBooleanReply implements JresReply {
// 
//     private final boolean verity;
// 
//     public JresBooleanReply(boolean verity) {
//         this.verity = verity;
//     }
// 
//     @Override
//     public JsonNode node() {
//         return null;
//     }
// 
//     public boolean verity() {
//         return verity;
//     }
// 
// }


import com.blacklocus.jres.BaseJresTest;
import com.blacklocus.jres.request.index.JresCreateIndex;
import com.blacklocus.jres.response.JresBooleanReply;
import org.junit.Assert;
import org.junit.Test;
/**
 * Copyright 2015 BlackLocus
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.blacklocus.jres.request.mapping;


public class JresTypeExistsTest extends BaseJresTest {

    @Test
    public void happy() {
        String index = "JresTypeExistsRequestTest_happy".toLowerCase();
        String type = "test";

// Path: jres-test/src/main/java/com/blacklocus/jres/BaseJresTest.java
// public class BaseJresTest {
// 
//     @BeforeClass
//     public static void startLocalElasticSearch() {
//         ElasticSearchTestInstance.triggerStaticInit();
//     }
// 
//     /**
//      * Configured to connect to a local ElasticSearch instance created specifically for unit testing
//      */
//     protected Jres jres = new Jres(Suppliers.ofInstance("http://localhost:9201"));
// 
// }
// 
// Path: jres-core/src/main/java/com/blacklocus/jres/request/index/JresCreateIndex.java
// public class JresCreateIndex extends JresJsonRequest<JresAcknowledgedReply> {
// 
//     private final String index;
//     private final Object settings;
// 
//     public JresCreateIndex(String index) {
//         this(index, null);
//     }
// 
//     public JresCreateIndex(String index, String settingsJson) {
//         super(JresAcknowledgedReply.class);
//         this.index = index;
//         this.settings = settingsJson;
//     }
// 
//     @Override
//     public String getHttpMethod() {
//         return HttpPut.METHOD_NAME;
//     }
// 
//     @Override
//     public String getPath() {
//         return index;
//     }
// 
//     @Override
//     public Object getPayload() {
//         return settings;
//     }
// 
// }
// 
// Path: jres-core/src/main/java/com/blacklocus/jres/response/JresBooleanReply.java
// public class JresBooleanReply implements JresReply {
// 
//     private final boolean verity;
// 
//     public JresBooleanReply(boolean verity) {
//         this.verity = verity;
//     }
// 
//     @Override
//     public JsonNode node() {
//         return null;
//     }
// 
//     public boolean verity() {
//         return verity;
//     }
// 
// }


// Path: jres-test/src/test/java/com/blacklocus/jres/request/mapping/JresTypeExistsTest.java
import com.blacklocus.jres.BaseJresTest;
import com.blacklocus.jres.request.index.JresCreateIndex;
import com.blacklocus.jres.response.JresBooleanReply;
import org.junit.Assert;
import org.junit.Test;

/**
 * Copyright 2015 BlackLocus
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.blacklocus.jres.request.mapping;


public class JresTypeExistsTest extends BaseJresTest {

    @Test
    public void happy() {
        String index = "JresTypeExistsRequestTest_happy".toLowerCase();
        String type = "test";

        jres.quest(new JresCreateIndex(index));