# \[Solved\] Testing (ESIntegTestCase): Install hunspell dictionary

**URL:** <https://discuss.elastic.co/t/solved-testing-esintegtestcase-install-hunspell-dictionary/56089>\
**Category:** Elasticsearch\
**Created:** [July 21, 2016, 11:16am UTC](https://discuss.elastic.co/t/solved-testing-esintegtestcase-install-hunspell-dictionary/56089 "2016-07-21T11:16:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tobiaswerner](https://avatars.discourse-cdn.com/v4/letter/t/eada6e/32.png) [@tobiaswerner](https://discuss.elastic.co/u/tobiaswerner)\
**Post date:** [July 21, 2016, 11:16am UTC](https://discuss.elastic.co/t/solved-testing-esintegtestcase-install-hunspell-dictionary/56089/1 "2016-07-21T11:16:39Z")

</div>

Hi folks,

hope I chose the correct category 😉  
I am trying to implement some test cases to get informed about possible problems if templates/mappings or queries do change.

There is no SLA, so tests must not focus on response time but on, lets say, "quality" - "is the result I am expecting within the first 10 matches if query is run on a limited, well-known datasource?"

So I've created a maven project with deps to ES 2.3.3

The test is extending ESIntegTestCase.  
Here I wanted to put my templates, create indices and run different queries against the created index.

We are using a hunspell tokenizer in our mappings.

Templates `PUT` is fine but creation of index throws an exeption "could not find hunspell dictionary [de\_DE]" what I expect to happen because I did not install it within the auto-started cluster.

To make a long story short: I am unsure how to apply the dictionary files to the automatically started cluster.

```
Caused by: ElasticsearchException[Could not find hunspell dictionary [de_DE]]
	at org.elasticsearch.indices.analysis.HunspellService.loadDictionary(HunspellService.java:163)
	at org.elasticsearch.indices.analysis.HunspellService.access$000(HunspellService.java:70)
	at org.elasticsearch.indices.analysis.HunspellService$1.load(HunspellService.java:96)
	at org.elasticsearch.indices.analysis.HunspellService$1.load(HunspellService.java:91)
	at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3527)
	at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2319)
	at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2282)
	at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2197)
	... 69 more 

```

Would appreciate if anyone could point me to right direction, even if I am on a completely wrong track!

Cheers,  
tobi

---

<div class="post-metadata">

**Author:** ![tobiaswerner](https://avatars.discourse-cdn.com/v4/letter/t/eada6e/32.png) [@tobiaswerner](https://discuss.elastic.co/u/tobiaswerner)\
**Post date:** [July 22, 2016, 10:09am UTC](https://discuss.elastic.co/t/solved-testing-esintegtestcase-install-hunspell-dictionary/56089/2 "2016-07-22T10:09:05Z")

</div>

Wrapped my head 'round that.  
Assuming I want to have my dictionary files below `/src/test/resources/config/`:

```
@Override
protected Settings nodeSettings(int nodeOrdinal) {
	Settings settings = Settings.builder()
			.put(super.nodeSettings(nodeOrdinal))
			.put("path.conf", this.getDataPath("/config"))
			.build();
	return settings;
}
```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 5, 2017, 10:33pm UTC](https://discuss.elastic.co/t/solved-testing-esintegtestcase-install-hunspell-dictionary/56089/3 "2017-07-05T22:33:26Z")

</div>


