Tabnine Logo
AbstractStringAssert.isNotNull
Code IndexAdd Tabnine to your IDE (free)

How to use
isNotNull
method
in
org.assertj.core.api.AbstractStringAssert

Best Java code snippets using org.assertj.core.api.AbstractStringAssert.isNotNull (Showing top 20 results out of 315)

origin: spring-projects/spring-session

  @Override
  public void doFilter(HttpServletRequest wrappedRequest) {
    String id = wrappedRequest.getSession().getId();
    assertThat(id).isNotNull();
    assertThat(wrappedRequest.getSession().getId()).isEqualTo(id);
    SessionRepositoryFilterTests.this.request.setAttribute(ID_ATTR, id);
  }
});
origin: spring-projects/spring-security

@Test
public void deserializeGrantedAuthorityTest() throws IOException {
  SimpleGrantedAuthority authority = mapper.readValue(AUTHORITY_JSON, SimpleGrantedAuthority.class);
  assertThat(authority).isNotNull();
  assertThat(authority.getAuthority()).isNotNull().isEqualTo("ROLE_USER");
}
origin: jdbi/jdbi

@Test
public void testToStringDoesntAttach() {
  assertThat(onDemand.toString()).isNotNull();
  verify(mockExtensionFactory, never()).attach(any(), any());
}
origin: spring-projects/spring-security

  @Test
  public void testGetAuthority() throws Exception {
    assertThat(authority.getAuthority()).isNotNull();
    assertThat(authority.getAuthority()).isEqualTo("testRole");
  }
}
origin: spring-projects/spring-security

@Test
public void text() {
  CryptoAssumptions.assumeCBCJCE();
  TextEncryptor encryptor = Encryptors.text("password", "5c0744940b5c369b");
  String result = encryptor.encrypt("text");
  assertThat(result).isNotNull();
  assertThat(result.equals("text")).isFalse();
  assertThat(encryptor.decrypt(result)).isEqualTo("text");
  assertThat(result.equals(encryptor.encrypt("text"))).isFalse();
}
origin: spring-projects/spring-security

@Test
public void preferred() {
  CryptoAssumptions.assumeGCMJCE();
  TextEncryptor encryptor = Encryptors.delux("password", "5c0744940b5c369b");
  String result = encryptor.encrypt("text");
  assertThat(result).isNotNull();
  assertThat(result.equals("text")).isFalse();
  assertThat(encryptor.decrypt(result)).isEqualTo("text");
  assertThat(result.equals(encryptor.encrypt("text"))).isFalse();
}
origin: spring-projects/spring-security

@Test
public void queryableText() {
  CryptoAssumptions.assumeCBCJCE();
  TextEncryptor encryptor = Encryptors.queryableText("password",
      "5c0744940b5c369b");
  String result = encryptor.encrypt("text");
  assertThat(result).isNotNull();
  assertThat(result.equals("text")).isFalse();
  assertThat(encryptor.decrypt(result)).isEqualTo("text");
  assertThat(result.equals(encryptor.encrypt("text"))).isTrue();
}
origin: jdbi/jdbi

@Test
public void testToString() {
  Spiffy s1 = dbRule.getSharedHandle().attach(Spiffy.class);
  Spiffy s2 = dbRule.getSharedHandle().attach(Spiffy.class);
  assertThat(s1.toString()).isNotNull();
  assertThat(s2.toString()).isNotNull();
  assertThat(s1.toString()).isNotEqualTo(s2.toString());
}
origin: spring-io/initializr

@Test
void installer() {
  ResponseEntity<String> response = getRestTemplate()
      .getForEntity(createUrl("install.sh"), String.class);
  assertThat(response.getStatusCode()).isEqualTo(HttpStatus.OK);
  assertThat(response.getBody()).isNotNull();
}
origin: testcontainers/testcontainers-java

@Test
public void shouldReturnBoltUrl() {
  String actual = neo4jContainer.getBoltUrl();
  assertThat(actual).isNotNull();
  assertThat(actual).startsWith("bolt://");
}
origin: testcontainers/testcontainers-java

  @Test
  public void shouldReturnHttpUrl() {
    String actual = neo4jContainer.getHttpUrl();

    assertThat(actual).isNotNull();
    assertThat(actual).startsWith("http://");
  }
}
origin: reactor/reactor-core

@Test
public void nullScenarioEmpty() {
  assertThat(new ErrorFormatter(null).scenarioPrefix)
      .isNotNull()
      .isEmpty();
}
origin: reactor/reactor-core

@Test
public void noScenarioEmpty() {
  assertThat(new ErrorFormatter("").scenarioPrefix)
      .isNotNull()
      .isEmpty();
}
origin: apache/geode

@Test
public void execHostNameShouldNeverReturnNull() throws IOException {
 String result = new HostName().execHostName();
 assertThat(result).isNotNull();
}
origin: spring-io/initializr

private void validateHttpIeHelpContent(ResponseEntity<String> response) {
  validateContentType(response, MediaType.TEXT_PLAIN);
  assertThat(response.getHeaders().getFirst(HttpHeaders.ETAG)).isNotNull();
  assertThat(response.getBody()).contains("Spring Initializr", "Examples:", "http")
      .doesNotContain("curl");
}
origin: spring-io/initializr

private void validateSpringBootHelpContent(ResponseEntity<String> response) {
  validateContentType(response, MediaType.TEXT_PLAIN);
  assertThat(response.getHeaders().getFirst(HttpHeaders.ETAG)).isNotNull();
  assertThat(response.getBody())
      .contains("Service capabilities", "Supported dependencies")
      .doesNotContain("Examples:", "curl");
}
origin: spring-projects/spring-security

  @Test
  public void buildWhenAuthorizationUriIncludesQueryParameterThenAuthorizationRequestUrlIncludesIt() {
    OAuth2AuthorizationRequest authorizationRequest =
        TestOAuth2AuthorizationRequests.request()
            .authorizationUri(AUTHORIZATION_URI +
                "?param1=value1&param2=value2").build();

    assertThat(authorizationRequest.getAuthorizationRequestUri()).isNotNull();
    assertThat(authorizationRequest.getAuthorizationRequestUri())
        .isEqualTo("https://provider.com/oauth2/authorize?" +
            "param1=value1&param2=value2&" +
            "response_type=code&client_id=client-id&state=state&" +
            "redirect_uri=https://example.com/authorize/oauth2/code/registration-id");
  }
}
origin: spring-io/initializr

@Test
void metadataWithHalAcceptHeader() {
  ResponseEntity<String> response = invokeHome(null, "application/hal+json");
  assertThat(response.getHeaders().getFirst(HttpHeaders.ETAG)).isNotNull();
  validateContentType(response, MainController.HAL_JSON_CONTENT_TYPE);
  validateCurrentMetadata(response.getBody());
}
origin: apache/geode

@Test
@Parameters({MAC_OSX_NAME, LINUX_OS_NAME, SOLARIS_OS_NAME, WINDOWS_OS_NAME})
public void shouldExecHostNameIfEnvValueNotAvailableOnOS(String osName) throws IOException {
 setHostNamePropertiesNull(osName);
 String result = new HostName().determineHostName();
 assertThat(result).isNotNull();
}
origin: spring-io/initializr

@Test
void metadataWithCurrentAcceptHeader() {
  getRequests().setFields("_links.maven-project", "dependencies.values[0]",
      "type.values[0]", "javaVersion.values[0]", "packaging.values[0]",
      "bootVersion.values[0]", "language.values[0]");
  ResponseEntity<String> response = invokeHome(null,
      "application/vnd.initializr.v2.1+json");
  assertThat(response.getHeaders().getFirst(HttpHeaders.ETAG)).isNotNull();
  validateContentType(response,
      AbstractInitializrIntegrationTests.CURRENT_METADATA_MEDIA_TYPE);
  validateCurrentMetadata(response.getBody());
}
org.assertj.core.apiAbstractStringAssertisNotNull

Popular methods of AbstractStringAssert

  • isEqualTo
  • contains
  • isNull
  • startsWith
  • isEmpty
  • isNotEqualTo
  • isNotEmpty
  • doesNotContain
  • as
  • matches
  • endsWith
  • isEqualToIgnoringCase
  • endsWith,
  • isEqualToIgnoringCase,
  • containsPattern,
  • isSameAs,
  • isEqualToIgnoringWhitespace,
  • isIn,
  • isNotBlank,
  • describedAs,
  • isEqualToNormalizingNewlines

Popular in Java

  • Creating JSON documents from java classes using gson
  • runOnUiThread (Activity)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • onCreateOptionsMenu (Activity)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • DataSource (javax.sql)
    An interface for the creation of Connection objects which represent a connection to a database. This
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now