code: public function minUppercase($n)
      {
          $this->constraints[] = (function (Password $str) use ($n) {
              if (preg_match_all("/\\p{Lu}/", $str) < $n) {
                  return sprintf("Password must contain at least %d uppercase letters.", $n);
              } else {
                  return true;
              }
          });
          return $this;
      }
docs: The minimum amount of uppercase letters (an uppercase letter that
  has a lowercase variant, from any language)
  @param int $n
  @return $this