<commit_before>describe("MapLinkView", function() {
  $a = window.sirius;
  
  beforeEach(function() {
    loadFixtures('context.menu.view.fixture.html');
    network = $a.scenario.get('networklist').get('network')[0];
    model = network.get('linklist').get('link')[0];

    expetedEncodedPath = "}r}eF`bmiVuGn@c@DwIhAiBT";
    legs = [
      {
        steps: [
          {
            path : [
              new google.maps.LatLng(37.83999, -122.29681000000001),
              new google.maps.LatLng(37.84138, -122.29705000000001),
              new google.maps.LatLng(37.84156, -122.29708000000001),
              new google.maps.LatLng(37.84328, -122.29745000000001),
              new google.maps.LatLng(37.84381000000001, -122.29756)
            ]
          }
        ]
      }
    ]
    spyOn($a.MapLinkView.prototype, 'clearSelected').andCallThrough();
    spyOn($a.MapLinkView.prototype, '_triggerClearSelectEvents').andCallThrough();
    spyOn($a.MapLinkView.prototype, 'linkSelect').andCallThrough();
    this.view = new $a.MapLinkView(model, network, legs);
  });
  
  afterEach(function() {
    this.view.remove();
  }); 
  
  describe("Instantiation", function() {
    it("should encode the path", function() {
      expect(this.view.encodedPath).toEqual(expetedEncodedPath);
    });
    
    it("should save encoded the path to linkgeometry", function() {
      lg = this.view.model.get('linkgeometry');
      encodedPath = lg.get('encodedpolyline').get('points').get('text');
      expect(encodedPath).toEqual(expetedEncodedPath);
    });
    
    it("should have made polyline object", function() {
      link = this.view.link
      expect(link).not.toBe(null);
    });
    
    it("should have made context menu for itself", function() {
      cm = model.get('contextMenu');
      expect(cm).not.toBe(null);
      menuItemLabels = _.pluck(cm.options.menuItems, 'label');
      expect(menuItemLabels).toEqual(_.pluck($a.link_context_menu,'label'));
    });
  });
  <commit_msg>Fix spelling of 'expected' in test<commit_after>describe("MapLinkView", function() {
  $a = window.sirius;
  
  beforeEach(function() {
    loadFixtures('context.menu.view.fixture.html');
    network = $a.scenario.get('networklist').get('network')[0];
    model = network.get('linklist').get('link')[0];

    expectedEncodedPath = "}r}eF`bmiVuGn@c@DwIhAiBT";
    legs = [
      {
        steps: [
          {
            path : [
              new google.maps.LatLng(37.83999, -122.29681000000001),
              new google.maps.LatLng(37.84138, -122.29705000000001),
              new google.maps.LatLng(37.84156, -122.29708000000001),
              new google.maps.LatLng(37.84328, -122.29745000000001),
              new google.maps.LatLng(37.84381000000001, -122.29756)
            ]
          }
        ]
      }
    ]
    spyOn($a.MapLinkView.prototype, 'clearSelected').andCallThrough();
    spyOn($a.MapLinkView.prototype, '_triggerClearSelectEvents').andCallThrough();
    spyOn($a.MapLinkView.prototype, 'linkSelect').andCallThrough();
    this.view = new $a.MapLinkView(model, network, legs);
  });
  
  afterEach(function() {
    this.view.remove();
  }); 
  
  describe("Instantiation", function() {
    it("should encode the path", function() {
      expect(this.view.encodedPath).toEqual(expectedEncodedPath);
    });
    
    it("should save encoded the path to linkgeometry", function() {
      lg = this.view.model.get('linkgeometry');
      encodedPath = lg.get('encodedpolyline').get('points').get('text');
      expect(encodedPath).toEqual(expectedEncodedPath);
    });
    
    it("should have made polyline object", function() {
      link = this.view.link
      expect(link).not.toBe(null);
    });
    
    it("should have made context menu for itself", function() {
      cm = model.get('contextMenu');
      expect(cm).not.toBe(null);
      menuItemLabels = _.pluck(cm.options.menuItems, 'label');
      expect(menuItemLabels).toEqual(_.pluck($a.link_context_menu,'label'));
    });
  });
  
{'fraction_non_alphanumeric': 0.16051844466600199, 'fraction_numerical': 0.06081754735792622, 'mean_word_length': 2.8660886319845855, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 10, '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': '6696726', 'n_tokens_mistral': 1468, 'n_tokens_neox': 1306, 'n_words': 181}