OkHttp Certificate Pinner does not throw exception

I am configuring my OkHttpClient and Retrofit with a CertificatePinner like follows and would expect it to throw an exception when I make a request, because the key is invalid. But all server requests work fine and do not throw an exception when using the below key. Am I missing something?

OkHttpClient client = OkHttpClient.Builder()
            // .addInterceptor(new LoggingInterceptor())
            .certificatePinner(
                    new CertificatePinner.Builder()
                            .add("*.mydomain.com", "sha256/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=")
                            .build())
            .build();

 Retrofit retrofit = new Retrofit.Builder()
            .baseUrl(endpoint)
            .client(client)
            .addConverterFactory(GsonConverterFactory.create(gson))
            .build();

I am using Retrofit 2.3.0