@Test
public void testSubscribedToNotAuthorizedTopic() {

    final String fakeUserName = "UnAuthUser";
    NettyUtils.userName(m_channel, fakeUserName);
    IAuthorizator mockAuthorizator = mock(IAuthorizator.class);
    when(mockAuthorizator.canRead(eq(new Topic(FAKE_TOPIC)), eq(fakeUserName), eq(FAKE_CLIENT_ID)))
        .thenReturn(false);
    m_processor.init(subscriptions, m_messagesStore, m_sessionStore, m_mockAuthenticator, true, mockAuthorizator,
            NO_OBSERVERS_INTERCEPTOR, this.sessionsRepository);
    connect();
    //Exercise
    MqttSubAckMessage subAckMsg = subscribeWithoutVerify(FAKE_TOPIC, AT_MOST_ONCE);
    verifyFailureQos(subAckMsg);
}