<commit_before>package de.is24.play.orientdb

import de.is24.play.orientdb.testsupport.OrientDBScope
import org.specs2.mutable.Specification
import play.api.test.{DefaultAwaitTimeout, FutureAwaits}

class EmbeddedOrientDBTest extends Specification with FutureAwaits with DefaultAwaitTimeout {

  sequential

  "An embedded server" should {

    "reach the server page" in new OrientDBScope {
      ok
    }

    "be able to perform dorway migration multiple times" in new OrientDBScope {
      executeDorway()

      await(dorway.getDatabaseSchemaVersion) must beEqualTo(2)
    }
    "be able to execute batch commands" in new OrientDBScope {
      val batchOperation = BatchOperation(transaction = true, operations = Seq(CommandOperation(language = "sql", command = "SELECT 1")))
      await(orientClient.executeBatch(batchOperation))

    }
  }

}<commit_msg>add implicit variant to client example<commit_after>package de.is24.play.orientdb

import de.is24.play.orientdb.testsupport.OrientDBScope
import org.specs2.mutable.Specification
import play.api.test.{DefaultAwaitTimeout, FutureAwaits}
import Operation._

class EmbeddedOrientDBTest extends Specification with FutureAwaits with DefaultAwaitTimeout {

  sequential

  "An embedded server" should {

    "reach the server page" in new OrientDBScope {
      ok
    }

    "be able to perform dorway migration multiple times" in new OrientDBScope {
      executeDorway()

      await(dorway.getDatabaseSchemaVersion) must beEqualTo(2)
    }
    "be able to execute batch commands" in new OrientDBScope {
      val batchOperation = BatchOperation(transaction = true, operations = Seq(CommandOperation(language = "sql", command = "SELECT 1")))
      await(orientClient.executeBatch(batchOperation))

      implicit val client = orientClient
      await(Seq("SELECT 1", "SELECT 2").transactionally.execute)

      await("INSERT INTO V SET notice = 'inserted transactionally'".transactionally.execute)
    }
  }

}
{'fraction_non_alphanumeric': 0.07934893184130214, 'fraction_numerical': 0.008138351983723296, 'mean_word_length': 4.2175066312997345, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1558888', 'n_tokens_mistral': 576, 'n_tokens_neox': 557, 'n_words': 152}