{"action":"created","comment":{"url":"https://api.github.com/repos/Stratio/sparkta/pulls/comments/30125025","id":30125025,"diff_hunk":"@@ -17,60 +17,80 @@\n package com.stratio.sparkta.aggregator\n \n import java.io.{Serializable => JSerializable}\n-import scala.collection.mutable\n-\n-import org.apache.spark._\n-import org.apache.spark.rdd.RDD\n-import org.apache.spark.streaming._\n-import org.junit.runner.RunWith\n-import org.scalatest.FlatSpec\n-import org.scalatest.junit.JUnitRunner\n \n import com.stratio.sparkta.plugin.bucketer.passthrough.PassthroughBucketer\n import com.stratio.sparkta.plugin.operator.count.CountOperator\n import com.stratio.sparkta.sdk._\n+import org.apache.spark.streaming.TestSuiteBase\n+import org.scalatest.{FeatureSpec, FlatSpec}\n \n-@RunWith(classOf[JUnitRunner])\n-class DataCubeSpec  extends FlatSpec{\n-\n-  \"DataCubeSpec\" should \"process the events queued\" in {\n-\n-    val myConf = new SparkConf()\n-      .setAppName(this.getClass.getSimpleName + \"\" + System.currentTimeMillis())\n-      .setMaster(\"local[2]\").set(\"spark.streaming.clock\", \"org.apache.spark.streaming.util.ManualClock\")\n-    val sc = new SparkContext(myConf)\n-    val ssc: StreamingContext = new StreamingContext(sc, Seconds(2))\n-    val clock = new ClockWrapper(ssc)\n-\n-    def myDim(i: Int) = new Dimension(\"myKey\" + i, new PassthroughBucketer().asInstanceOf[Bucketer])\n-\n-    def getDimensions: Seq[Dimension] = (0 until 10) map (i => myDim(i))\n-\n-    def getComponents: Seq[(Dimension, BucketType)] = (0 until 1) map (i => (myDim(i), Bucketer.identity))\n-\n-    def getOperators: Seq[Operator] = (0 until 1) map (i => new CountOperator(Map(\"prop\" -> \"propValue\"\n-      .asInstanceOf[JSerializable])))\n-\n-    val myRollups: Seq[Rollup] = (0 until 2) map (i => new Rollup(components = getComponents, operators = getOperators))\n-\n-    val events = mutable.Queue[RDD[Event]]()\n-    val myDimensions: Seq[Dimension] = getDimensions\n-\n-    val getEvents: Seq[Event] = (0 until 10) map (i => new Event(Map(\"key\" + i -> System.currentTimeMillis()\n-      .asInstanceOf[JSerializable]), Some(\"myRaw event data here\")))\n-\n-\n-    val dc: DataCube = new DataCube(myDimensions, myRollups)\n-    val result = dc.setUp(ssc.queueStream(events))\n-    result.foreach(i => i.print)\n-\n-    assert(result.size == 2)\n-\n-    ssc.start()\n-    events += sc.makeRDD(getEvents)\n-    clock.advance(2)\n-\n-    ssc.stop()\n-\n+/**\n+ * Tests over DataCube operations.\n+ * @author anistal\n+ */\n+class DataCubeSpec extends TestSuiteBase {","path":"aggregator/src/test/scala/com/stratio/sparkta/aggregator/DataCubeSpec.scala","position":65,"original_position":65,"commit_id":"81651c1c2b548c076e3e1e795043187dd4070ebb","original_commit_id":"81651c1c2b548c076e3e1e795043187dd4070ebb","user":{"login":"anistal","id":166239,"avatar_url":"https://avatars.githubusercontent.com/u/166239?v=3","gravatar_id":"","url":"https://api.github.com/users/anistal","html_url":"https://github.com/anistal","followers_url":"https://api.github.com/users/anistal/followers","following_url":"https://api.github.com/users/anistal/following{/other_user}","gists_url":"https://api.github.com/users/anistal/gists{/gist_id}","starred_url":"https://api.github.com/users/anistal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anistal/subscriptions","organizations_url":"https://api.github.com/users/anistal/orgs","repos_url":"https://api.github.com/users/anistal/repos","events_url":"https://api.github.com/users/anistal/events{/privacy}","received_events_url":"https://api.github.com/users/anistal/received_events","type":"User","site_admin":false},"body":"Is it really needed? DataCubeSpec is extending from TestSuiteBase and in turn extends from FanSuite. Scala should be run this test without use JUnitRunner.  Am I wrong?","created_at":"2015-05-12T11:35:08Z","updated_at":"2015-05-12T11:35:08Z","html_url":"https://github.com/Stratio/sparkta/pull/143#discussion_r30125025","pull_request_url":"https://api.github.com/repos/Stratio/sparkta/pulls/143","_links":{"self":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/comments/30125025"},"html":{"href":"https://github.com/Stratio/sparkta/pull/143#discussion_r30125025"},"pull_request":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/143"}}},"pull_request":{"url":"https://api.github.com/repos/Stratio/sparkta/pulls/143","id":35216024,"html_url":"https://github.com/Stratio/sparkta/pull/143","diff_url":"https://github.com/Stratio/sparkta/pull/143.diff","patch_url":"https://github.com/Stratio/sparkta/pull/143.patch","issue_url":"https://api.github.com/repos/Stratio/sparkta/issues/143","number":143,"state":"open","locked":false,"title":"Feature/datacube testing","user":{"login":"anistal","id":166239,"avatar_url":"https://avatars.githubusercontent.com/u/166239?v=3","gravatar_id":"","url":"https://api.github.com/users/anistal","html_url":"https://github.com/anistal","followers_url":"https://api.github.com/users/anistal/followers","following_url":"https://api.github.com/users/anistal/following{/other_user}","gists_url":"https://api.github.com/users/anistal/gists{/gist_id}","starred_url":"https://api.github.com/users/anistal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anistal/subscriptions","organizations_url":"https://api.github.com/users/anistal/orgs","repos_url":"https://api.github.com/users/anistal/repos","events_url":"https://api.github.com/users/anistal/events{/privacy}","received_events_url":"https://api.github.com/users/anistal/received_events","type":"User","site_admin":false},"body":"DataCube musts be tested using Sparkt's TestSuiteBase such as tests in its repository.","created_at":"2015-05-12T11:15:21Z","updated_at":"2015-05-12T11:35:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cbdd77574dc2b0b50120c4ec8b237343065e43f6","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Stratio/sparkta/pulls/143/commits","review_comments_url":"https://api.github.com/repos/Stratio/sparkta/pulls/143/comments","review_comment_url":"https://api.github.com/repos/Stratio/sparkta/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Stratio/sparkta/issues/143/comments","statuses_url":"https://api.github.com/repos/Stratio/sparkta/statuses/81651c1c2b548c076e3e1e795043187dd4070ebb","head":{"label":"anistal:feature/datacube-testing","ref":"feature/datacube-testing","sha":"81651c1c2b548c076e3e1e795043187dd4070ebb","user":{"login":"anistal","id":166239,"avatar_url":"https://avatars.githubusercontent.com/u/166239?v=3","gravatar_id":"","url":"https://api.github.com/users/anistal","html_url":"https://github.com/anistal","followers_url":"https://api.github.com/users/anistal/followers","following_url":"https://api.github.com/users/anistal/following{/other_user}","gists_url":"https://api.github.com/users/anistal/gists{/gist_id}","starred_url":"https://api.github.com/users/anistal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anistal/subscriptions","organizations_url":"https://api.github.com/users/anistal/orgs","repos_url":"https://api.github.com/users/anistal/repos","events_url":"https://api.github.com/users/anistal/events{/privacy}","received_events_url":"https://api.github.com/users/anistal/received_events","type":"User","site_admin":false},"repo":{"id":35228345,"name":"sparkta","full_name":"anistal/sparkta","owner":{"login":"anistal","id":166239,"avatar_url":"https://avatars.githubusercontent.com/u/166239?v=3","gravatar_id":"","url":"https://api.github.com/users/anistal","html_url":"https://github.com/anistal","followers_url":"https://api.github.com/users/anistal/followers","following_url":"https://api.github.com/users/anistal/following{/other_user}","gists_url":"https://api.github.com/users/anistal/gists{/gist_id}","starred_url":"https://api.github.com/users/anistal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anistal/subscriptions","organizations_url":"https://api.github.com/users/anistal/orgs","repos_url":"https://api.github.com/users/anistal/repos","events_url":"https://api.github.com/users/anistal/events{/privacy}","received_events_url":"https://api.github.com/users/anistal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/anistal/sparkta","description":"Real Time Aggregation based on Spark Streaming","fork":true,"url":"https://api.github.com/repos/anistal/sparkta","forks_url":"https://api.github.com/repos/anistal/sparkta/forks","keys_url":"https://api.github.com/repos/anistal/sparkta/keys{/key_id}","collaborators_url":"https://api.github.com/repos/anistal/sparkta/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/anistal/sparkta/teams","hooks_url":"https://api.github.com/repos/anistal/sparkta/hooks","issue_events_url":"https://api.github.com/repos/anistal/sparkta/issues/events{/number}","events_url":"https://api.github.com/repos/anistal/sparkta/events","assignees_url":"https://api.github.com/repos/anistal/sparkta/assignees{/user}","branches_url":"https://api.github.com/repos/anistal/sparkta/branches{/branch}","tags_url":"https://api.github.com/repos/anistal/sparkta/tags","blobs_url":"https://api.github.com/repos/anistal/sparkta/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/anistal/sparkta/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/anistal/sparkta/git/refs{/sha}","trees_url":"https://api.github.com/repos/anistal/sparkta/git/trees{/sha}","statuses_url":"https://api.github.com/repos/anistal/sparkta/statuses/{sha}","languages_url":"https://api.github.com/repos/anistal/sparkta/languages","stargazers_url":"https://api.github.com/repos/anistal/sparkta/stargazers","contributors_url":"https://api.github.com/repos/anistal/sparkta/contributors","subscribers_url":"https://api.github.com/repos/anistal/sparkta/subscribers","subscription_url":"https://api.github.com/repos/anistal/sparkta/subscription","commits_url":"https://api.github.com/repos/anistal/sparkta/commits{/sha}","git_commits_url":"https://api.github.com/repos/anistal/sparkta/git/commits{/sha}","comments_url":"https://api.github.com/repos/anistal/sparkta/comments{/number}","issue_comment_url":"https://api.github.com/repos/anistal/sparkta/issues/comments{/number}","contents_url":"https://api.github.com/repos/anistal/sparkta/contents/{+path}","compare_url":"https://api.github.com/repos/anistal/sparkta/compare/{base}...{head}","merges_url":"https://api.github.com/repos/anistal/sparkta/merges","archive_url":"https://api.github.com/repos/anistal/sparkta/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/anistal/sparkta/downloads","issues_url":"https://api.github.com/repos/anistal/sparkta/issues{/number}","pulls_url":"https://api.github.com/repos/anistal/sparkta/pulls{/number}","milestones_url":"https://api.github.com/repos/anistal/sparkta/milestones{/number}","notifications_url":"https://api.github.com/repos/anistal/sparkta/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/anistal/sparkta/labels{/name}","releases_url":"https://api.github.com/repos/anistal/sparkta/releases{/id}","created_at":"2015-05-07T15:34:52Z","updated_at":"2015-05-07T15:34:53Z","pushed_at":"2015-05-12T11:14:40Z","git_url":"git://github.com/anistal/sparkta.git","ssh_url":"git@github.com:anistal/sparkta.git","clone_url":"https://github.com/anistal/sparkta.git","svn_url":"https://github.com/anistal/sparkta","homepage":"http://www.stratio.com","size":23721,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Stratio:master","ref":"master","sha":"2a4aad75a7f4266d460de5c9d4160f23395e09b0","user":{"login":"Stratio","id":5228027,"avatar_url":"https://avatars.githubusercontent.com/u/5228027?v=3","gravatar_id":"","url":"https://api.github.com/users/Stratio","html_url":"https://github.com/Stratio","followers_url":"https://api.github.com/users/Stratio/followers","following_url":"https://api.github.com/users/Stratio/following{/other_user}","gists_url":"https://api.github.com/users/Stratio/gists{/gist_id}","starred_url":"https://api.github.com/users/Stratio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Stratio/subscriptions","organizations_url":"https://api.github.com/users/Stratio/orgs","repos_url":"https://api.github.com/users/Stratio/repos","events_url":"https://api.github.com/users/Stratio/events{/privacy}","received_events_url":"https://api.github.com/users/Stratio/received_events","type":"Organization","site_admin":false},"repo":{"id":30288112,"name":"sparkta","full_name":"Stratio/sparkta","owner":{"login":"Stratio","id":5228027,"avatar_url":"https://avatars.githubusercontent.com/u/5228027?v=3","gravatar_id":"","url":"https://api.github.com/users/Stratio","html_url":"https://github.com/Stratio","followers_url":"https://api.github.com/users/Stratio/followers","following_url":"https://api.github.com/users/Stratio/following{/other_user}","gists_url":"https://api.github.com/users/Stratio/gists{/gist_id}","starred_url":"https://api.github.com/users/Stratio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Stratio/subscriptions","organizations_url":"https://api.github.com/users/Stratio/orgs","repos_url":"https://api.github.com/users/Stratio/repos","events_url":"https://api.github.com/users/Stratio/events{/privacy}","received_events_url":"https://api.github.com/users/Stratio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Stratio/sparkta","description":"Real Time Aggregation based on Spark Streaming","fork":false,"url":"https://api.github.com/repos/Stratio/sparkta","forks_url":"https://api.github.com/repos/Stratio/sparkta/forks","keys_url":"https://api.github.com/repos/Stratio/sparkta/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Stratio/sparkta/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Stratio/sparkta/teams","hooks_url":"https://api.github.com/repos/Stratio/sparkta/hooks","issue_events_url":"https://api.github.com/repos/Stratio/sparkta/issues/events{/number}","events_url":"https://api.github.com/repos/Stratio/sparkta/events","assignees_url":"https://api.github.com/repos/Stratio/sparkta/assignees{/user}","branches_url":"https://api.github.com/repos/Stratio/sparkta/branches{/branch}","tags_url":"https://api.github.com/repos/Stratio/sparkta/tags","blobs_url":"https://api.github.com/repos/Stratio/sparkta/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Stratio/sparkta/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Stratio/sparkta/git/refs{/sha}","trees_url":"https://api.github.com/repos/Stratio/sparkta/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Stratio/sparkta/statuses/{sha}","languages_url":"https://api.github.com/repos/Stratio/sparkta/languages","stargazers_url":"https://api.github.com/repos/Stratio/sparkta/stargazers","contributors_url":"https://api.github.com/repos/Stratio/sparkta/contributors","subscribers_url":"https://api.github.com/repos/Stratio/sparkta/subscribers","subscription_url":"https://api.github.com/repos/Stratio/sparkta/subscription","commits_url":"https://api.github.com/repos/Stratio/sparkta/commits{/sha}","git_commits_url":"https://api.github.com/repos/Stratio/sparkta/git/commits{/sha}","comments_url":"https://api.github.com/repos/Stratio/sparkta/comments{/number}","issue_comment_url":"https://api.github.com/repos/Stratio/sparkta/issues/comments{/number}","contents_url":"https://api.github.com/repos/Stratio/sparkta/contents/{+path}","compare_url":"https://api.github.com/repos/Stratio/sparkta/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Stratio/sparkta/merges","archive_url":"https://api.github.com/repos/Stratio/sparkta/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Stratio/sparkta/downloads","issues_url":"https://api.github.com/repos/Stratio/sparkta/issues{/number}","pulls_url":"https://api.github.com/repos/Stratio/sparkta/pulls{/number}","milestones_url":"https://api.github.com/repos/Stratio/sparkta/milestones{/number}","notifications_url":"https://api.github.com/repos/Stratio/sparkta/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Stratio/sparkta/labels{/name}","releases_url":"https://api.github.com/repos/Stratio/sparkta/releases{/id}","created_at":"2015-02-04T08:04:40Z","updated_at":"2015-05-11T17:45:34Z","pushed_at":"2015-05-12T11:15:23Z","git_url":"git://github.com/Stratio/sparkta.git","ssh_url":"git@github.com:Stratio/sparkta.git","clone_url":"https://github.com/Stratio/sparkta.git","svn_url":"https://github.com/Stratio/sparkta","homepage":"http://www.stratio.com","size":23721,"stargazers_count":33,"watchers_count":33,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":28,"forks":7,"open_issues":28,"watchers":33,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/143"},"html":{"href":"https://github.com/Stratio/sparkta/pull/143"},"issue":{"href":"https://api.github.com/repos/Stratio/sparkta/issues/143"},"comments":{"href":"https://api.github.com/repos/Stratio/sparkta/issues/143/comments"},"review_comments":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/143/comments"},"review_comment":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Stratio/sparkta/pulls/143/commits"},"statuses":{"href":"https://api.github.com/repos/Stratio/sparkta/statuses/81651c1c2b548c076e3e1e795043187dd4070ebb"}}}}