<commit_before>path = require 'path'
{Site} = require 'telepath'
Project = require '../src/project'
Git = require '../src/git'

describe "Project replication", ->
  [doc1, doc2, project1, project2] = []

  beforeEach ->
    # pretend that home-1/project and home-2/project map to the same git repository url
    spyOn(Git, 'open').andReturn
      getOriginUrl: -> 'git://server/project.git'
      destroy: ->

    projectHome1 = path.join(__dirname, 'fixtures', 'replication', 'home-1')
    projectHome2 = path.join(__dirname, 'fixtures', 'replication', 'home-2')
    config.set('core.projectHome', projectHome1)
    project1 = new Project(path.join(projectHome1, 'project'))
    project1.bufferForPathSync('file-1.txt')<commit_msg>Stub refresh methods in replication spec<commit_after>path = require 'path'
{Site} = require 'telepath'
Project = require '../src/project'
Git = require '../src/git'

describe "Project replication", ->
  [doc1, doc2, project1, project2] = []

  beforeEach ->
    # pretend that home-1/project and home-2/project map to the same git repository url
    spyOn(Git, 'open').andReturn
      getOriginUrl: -> 'git://server/project.git'
      destroy: ->
      refreshIndex: ->
      refreshStatus: ->

    projectHome1 = path.join(__dirname, 'fixtures', 'replication', 'home-1')
    projectHome2 = path.join(__dirname, 'fixtures', 'replication', 'home-2')
    config.set('core.projectHome', projectHome1)
    project1 = new Project(path.join(projectHome1, 'project'))
    project1.bufferForPathSync('file-1.txt')
{'fraction_non_alphanumeric': 0.15344603381014305, 'fraction_numerical': 0.01950585175552666, 'mean_word_length': 3.9012738853503186, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, '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': '232196', 'n_tokens_mistral': 487, 'n_tokens_neox': 476, 'n_words': 114}