               service
               "test")]
          (testing "when environment info reset in the cache"
-           (is (not (nil? production-cache-id-after-first-update)))
-           (is (not (nil? test-cache-id-after-first-update)))
+           (is (= 2 production-cache-id-after-first-update))
+           (is (= 2 test-cache-id-after-first-update))
            (jruby-protocol/set-environment-class-info-tag!
             service
             "production"

                   service
                   "test")))
           (testing "and environment expired between get and corresponding set"
             (let [production-cache-id-after-second-update
                   (jruby-protocol/get-environment-class-info-cache-generation-id!
                    service
                    "production")
                   _ (jruby-protocol/mark-environment-expired! service
                                                               "production")
                   production-cache-id-after-third-update
                   (jruby-protocol/get-environment-class-info-cache-generation-id!
                    service
                    "production")]
               (is (not= production-cache-id-after-first-update
                         production-cache-id-after-second-update))
               (is (= nil (jruby-protocol/get-environment-class-info-tag
                           service
                           "production"))

         (is (nil? (jruby-protocol/get-environment-class-info-tag
                    service
                    "production")))
         (is (= 1 production-cache-id-before-first-update)))
       (testing "when environment info first set to cache"
         (jruby-protocol/set-environment-class-info-tag!
          service
