title: How to conditionally run test specs - Angular Protractor Jasmine
body: <p>I am using protractor jasmine for e2e test of an angular single page application. Consider the following code snippet.</p>
  
  <pre><code>describe('Search', function(){
    it('Should Open the search modal popup', function() {
       //code
       expect(modalOpened).toBe(true)
    })
  
    it('Search should return results', function(){
  
    })
    it('Search should not return results', function() {
  
    })
  })
  </code></pre>
  
  <p>In the above the example if <code>Should Open the search modal popup</code> fails then specs below <code>Should Open the search modal popup</code> and <code>Should Open the search modal popup</code> will also fail, because the modal itself is not open. So there is no point in running the below specs. Can I conditionally run the last two specs? Like only if the first spec has passed, the below specs should run.</p>