Skip to content

Commit

Permalink
Move test to neo4j module instead of kernel-enterpise
Browse files Browse the repository at this point in the history
  • Loading branch information
MishaDemianenko committed Sep 27, 2016
1 parent 82d77eb commit 8829602
Showing 1 changed file with 11 additions and 11 deletions.
Expand Up @@ -5,19 +5,19 @@
* This file is part of Neo4j.
*
* Neo4j is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
* GNU General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package org.neo4j.kernel.impl.enterprise;
package schema;

import org.apache.commons.lang3.RandomStringUtils;
import org.junit.Rule;
Expand Down Expand Up @@ -74,14 +74,13 @@ public void populateDbWithConcurrentUpdates() throws Exception
}

List<Populator> populators = new ArrayList<>();
for ( int i = 0; i < 10; i++ )
for ( int i = 0; i < 5; i++ )
{
Populator populator = new Populator( database, counter );
populators.add( populator );
populator.start();
}


try ( Transaction transaction = database.beginTx() )
{
database.schema().indexFor( Label.label( "label10" ) ).on( "property" ).create();
Expand Down Expand Up @@ -112,7 +111,7 @@ private class Populator extends Thread
private long totalNodes;
private volatile boolean terminate;

public Populator( GraphDatabaseService databaseService, long totalNodes )
Populator( GraphDatabaseService databaseService, long totalNodes )
{
this.databaseService = databaseService;
this.totalNodes = totalNodes;
Expand Down Expand Up @@ -154,12 +153,13 @@ public void run()
}
catch ( Exception e )
{
transaction.failure();
}
}
}
}

public void terminate()
void terminate()
{
terminate = true;
}
Expand Down

0 comments on commit 8829602

Please sign in to comment.