<commit_before>package com.odobo.filestorage.rackspace

import com.bertramlabs.plugins.karman.KarmanConfigHolder
import com.bertramlabs.plugins.karman.StorageProvider
import com.bertramlabs.plugins.karman.local.LocalStorageProvider
import spock.lang.Specification

/**
 * TODO: write doc
 */
class RackspaceStorageProviderSpec extends Specification {

    def "it can be created"() {
        given:
        KarmanConfigHolder.providerTypes << ["${RackspaceStorageProvider.name}": RackspaceStorageProvider]

        when:
        StorageProvider storageProvider = StorageProvider.create(provider: RackspaceStorageProvider.name, username: 'test', secretKey:'test', region:'uk')

        then:
        storageProvider
    }
}<commit_msg>Given a registered provider, we can use the factory<commit_after>package com.odobo.filestorage.rackspace

import com.bertramlabs.plugins.karman.KarmanConfigHolder
import com.bertramlabs.plugins.karman.StorageProvider
import com.bertramlabs.plugins.karman.local.LocalStorageProvider
import spock.lang.Specification

/**
 * TODO: write doc
 */
class RackspaceStorageProviderSpec extends Specification {

    def "it can be created"() {
        given:
        RackspaceStorageProvider.registerProvider()

        when:
        StorageProvider storageProvider = StorageProvider.create(provider: 'rackspace', username: 'test', secretKey:'test', region:'uk')

        then:
        storageProvider
    }
}
{'fraction_non_alphanumeric': 0.09141660851360782, 'fraction_numerical': 0.0, 'mean_word_length': 4.350746268656716, 'pattern_counts': {'":': 1, '<': 5, '<?xml version=': 0, '>': 3, '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': '5329262', 'n_tokens_mistral': 406, 'n_tokens_neox': 390, 'n_words': 80}