GrailsTestTransactionInterceptor (Grails 6.0.0)

Package: org.grails.test.support

## [Groovy] Class GrailsTestTransactionInterceptor

- org.grails.test.support.GrailsTestTransactionInterceptor

-     class GrailsTestTransactionInterceptor
      extends java.lang.Object

  Establishes a rollback only transaction for running a test in.

- - ### Field Summary

    Fields
    Modifiers | Name | Description
    --- | --- | ---
    `private static java.lang.String` | `TRANSACTIONAL` |
    `private org.springframework.context.ApplicationContext` | `applicationContext` |
    `protected java.util.Map<java.lang.String, org.springframework.transaction.PlatformTransactionManager>` | `transactionManagers` |
    `protected java.util.Map<java.lang.String, org.springframework.transaction.TransactionStatus>` | `transactionStatuses` |

  - ### Properties Summary

    Properties
    Type | Name and description
    --- | ---
    `static java.lang.String` | `TRANSACTIONAL`
    `org.springframework.context.ApplicationContext` | `applicationContext`

  - ### Constructor Summary

    Constructors
    Constructor and description
    `GrailsTestTransactionInterceptor (org.springframework.context.ApplicationContext applicationContext)`

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `void` | `destroy()` Rolls back the current transaction.
    `` | `void` | `init()` Establishes a transaction.
    `` | `boolean` | `isTransactional(java.lang.Object test)` A test is non transactional if it defines an instance or static property name 'transactional' with a value of `false`.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class java.lang.Object` | `java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()`

- - ### Field Detail

    - #### private static final java.lang.String TRANSACTIONAL

    - #### private org.springframework.context.ApplicationContext applicationContext

    - #### protected java.util.Map<java.lang.String, org.springframework.transaction.PlatformTransactionManager> transactionManagers

    - #### protected java.util.Map<java.lang.String, org.springframework.transaction.TransactionStatus> transactionStatuses

  - ### Property Detail

    - #### static final java.lang.String TRANSACTIONAL

    - #### org.springframework.context.ApplicationContext applicationContext

  - ### Constructor Detail

    - #### GrailsTestTransactionInterceptor(org.springframework.context.ApplicationContext applicationContext)

  - ### Method Detail

    - #### void destroy()

      Rolls back the current transaction.

    - #### void init()

      Establishes a transaction.

    - #### boolean isTransactional(java.lang.Object test)

      A test is non transactional if it defines an instance or static property name 'transactional' with a value of `false`.