<commit_before>/*
   Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
   SPDX-License-Identifier: Apache-2.0
*/

import aws.sdk.kotlin.services.elasticbeanstalk.ElasticBeanstalkClient
import com.aws.example.*
import kotlinx.coroutines.runBlocking
import org.junit.jupiter.api.*
import org.junit.jupiter.api.Assertions.assertTrue
import org.junit.jupiter.api.MethodOrderer.OrderAnnotation
import java.io.IOException
import java.net.URISyntaxException
import java.util.*
import java.util.concurrent.TimeUnit

@TestInstance(TestInstance.Lifecycle.PER_CLASS)
@TestMethodOrder(OrderAnnotation::class)
class ElasticBeanstalkTest {

    lateinit var beanstalkClient: ElasticBeanstalkClient
    var appName: String = ""
    var envName: String = ""
    var appArn: String = ""
    var envArn: String = ""

    @BeforeAll
    @Throws(IOException::class, URISyntaxException::class)
    fun setUp() {
        beanstalkClient = ElasticBeanstalkClient{ region = "us-east-1" }

        try {
            ElasticBeanstalkTest::class.java.classLoader.getResourceAsStream("config.properties").use { input ->
                val prop = Properties()
                if (input == null) {
                    println("Sorry, unable to find config.properties")
                    return
                }

                //load a properties file from class path, inside static method
                prop.load(input)

                // Populate the data members required for all tests
                appName = prop.getProperty("appName")
                envName = prop.getProperty("envName")
            }
        } catch (ex: IOException) {
            ex.printStackTrace()
        }<commit_msg>Update ElasticBeanstalkTest.kt<commit_after>/*
   Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
   SPDX-License-Identifier: Apache-2.0
*/

import aws.sdk.kotlin.services.elasticbeanstalk.ElasticBeanstalkClient
import com.aws.example.*
import kotlinx.coroutines.runBlocking
import org.junit.jupiter.api.*
import org.junit.jupiter.api.Assertions.assertTrue
import org.junit.jupiter.api.MethodOrderer.OrderAnnotation
import java.io.IOException
import java.net.URISyntaxException
import java.util.*
import java.util.concurrent.TimeUnit

@TestInstance(TestInstance.Lifecycle.PER_CLASS)
@TestMethodOrder(OrderAnnotation::class)
class ElasticBeanstalkTest {

    lateinit var beanstalkClient: ElasticBeanstalkClient
    var appName: String = ""
    var envName: String = ""
    var appArn: String = ""
    var envArn: String = ""

    @BeforeAll
    @Throws(IOException::class, URISyntaxException::class)
    fun setUp() {
        beanstalkClient = ElasticBeanstalkClient{ region = "us-east-1" }

        try {
            ElasticBeanstalkTest::class.java.classLoader.getResourceAsStream("config.properties").use { input ->
                val prop = Properties()
                if (input == null) {
                    println("Sorry, unable to find config.properties")
                    return
                }

                prop.load(input)
                appName = prop.getProperty("appName")
                envName = prop.getProperty("envName")
            }
        } catch (ex: IOException) {
            ex.printStackTrace()
        }
{'fraction_non_alphanumeric': 0.09751609935602576, 'fraction_numerical': 0.0018399264029438822, 'mean_word_length': 2.652855543113102, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5045669', 'n_tokens_mistral': 930, 'n_tokens_neox': 880, 'n_words': 189}