<commit_before>'use strict';

require('../qunit_extensions');
var Surface = require('../../../ui/Surface');
var DocumentSession = require('../../../model/DocumentSession');

function StubSurface(doc, containerId) {

  this.name = 'test_surface';
  this.containerId = containerId;
  this.documentSession = new DocumentSession(doc);

  this.getName = function() {
    return this.name;
  };

  this.getDocument = function() {
    return doc;
  };

  this.getDocumentSession = function() {
    return this.documentSession;
  };

  this.getSelection = function() {
    return this.documentSession.getSelection();
  };

  this.setSelection = function(sel) {
    this._setSelection(sel);
  };

  this._setSelection = function(sel) {
    this.documentSession.setSelection(sel);
  };

  this.getContainerId = function() {
    return this.containerId;
  };

  this.emit = function() {};

  this.rerenderDomSelection = function() {};

  this.transaction = Surface.prototype.transaction;

  this.copy = Surface.prototype.copy;

}

module.exports = StubSurface;<commit_msg>Fix regressions.<commit_after>'use strict';

require('../qunit_extensions');
var Surface = require('../../../ui/Surface');
var DocumentSession = require('../../../model/DocumentSession');

function StubSurface(doc, containerId) {

  this.name = 'test_surface';
  this.containerId = containerId;
  this.documentSession = new DocumentSession(doc);

  this.getName = function() {
    return this.name;
  };

  this.getDocument = function() {
    return doc;
  };

  this.getDocumentSession = function() {
    return this.documentSession;
  };

  this.getSelection = function() {
    return this.documentSession.getSelection();
  };

  this.setSelection = function(sel) {
    this._setSelection(sel);
  };

  this._setSelection = function(sel) {
    this.documentSession.setSelection(sel);
  };

  this.getContainerId = function() {
    return this.containerId;
  };

  this.isContainerEditor = function() {
    return !!this.containerId;
  };

  this.emit = function() {};

  this.rerenderDomSelection = function() {};

  this.transaction = Surface.prototype.transaction;

  this.copy = Surface.prototype.copy;

}

module.exports = StubSurface;
{'fraction_non_alphanumeric': 0.1516802906448683, 'fraction_numerical': 0.0, 'mean_word_length': 3.6772823779193207, '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': '3922327', 'n_tokens_mistral': 674, 'n_tokens_neox': 640, 'n_words': 114}