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

  • Start an intent from android
  • requestLocationUpdates (LocationManager)
  • setRequestProperty (URLConnection)
  • putExtra (Intent)
  • Container (java.awt)
    A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT co
  • MalformedURLException (java.net)
    This exception is thrown when a program attempts to create an URL from an incorrect specification.
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • SortedSet (java.util)
    SortedSet is a Set which iterates over its elements in a sorted order. The order is determined eithe
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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