summaryrefslogtreecommitdiffstats
path: root/config/src/test/java/com/yahoo/config/subscription/ConfigInterruptedExceptionTest.java
blob: d760a1c1b7298099627073ddb0acb47ab9d9c191 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.config.subscription;

import org.junit.Test;

import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertThat;

/**
 * @author lulf
 * @since 5.1
 */
public class ConfigInterruptedExceptionTest {
    @Test
    public void require_that_throwable_is_preserved() {
        ConfigInterruptedException e = new ConfigInterruptedException(new RuntimeException("foo"));
        assertThat(e.getCause().getMessage(), is("foo"));
    }
}