This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"nodes": [ | |
{ | |
"id": "n0", | |
"label": "A node", | |
"x": 0, | |
"y": 0, | |
"size": 3 | |
}, | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { IFieldResolver } from 'graphql-tools'; | |
import { DocumentNode } from 'graphql'; | |
import { ResolverContext } from '.'; | |
interface InputVariablesShape<TInput> { | |
input: TInput; | |
} | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe("The Home Page", () => { | |
it("successfully loads", () => { | |
cy.visit("/"); | |
}); | |
it("can visit a blog post link from the home page", () => { | |
cy.visit("/"); | |
cy.get("#post-page-link").click(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare global { | |
namespace Cypress { | |
interface Chainable<Subject> { | |
createFooBar: () => Chainable<string>; | |
} | |
} | |
} | |
/** | |
* Creates a foo and returns a bar. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: Searching on DuckDuckGo | |
As a web surfer, I want to search DuckDuckGo, so that I can learn new things. | |
Background: | |
Given I am on DuckDuckGos website | |
Scenario: Simple DuckDuckGo search | |
When the search phrase "panda" is entered | |
Then results for "panda" are shown |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Given } from 'cypress-cucumber-preprocessor/steps'; | |
Given('I am on DuckDuckGos website', () => { | |
cy.visit('https://duckduckgo.com'); | |
}); | |
When('the search phrase "panda" is entered', () => { | |
... | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Takes a snapshot of the application at the moment this method is called. | |
* | |
* When running in headless mode, it takes a snapshot with Percy, which is | |
* useful for testing purposes when integrated with our CI process. | |
* | |
* When running in headed mode, it takes a Cypress screenshot instead, | |
* which is more useful for allowing a developer to see a preview. | |
* | |
* @param description A string that describes the snapshot. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cypress-my-app: | |
working_directory: '~/Development/myapp' | |
parallelism: 3 | |
steps: | |
- run: | |
name: 'Run cypress tests' | |
command: | | |
cypress run --record -- --parallel --group $CIRCLE_JOB --ci-build-id $CIRCLE_WORKFLOW_ID |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"version": "0.0.0-development", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"publishConfig": { "access": "public", "branches": ["master"] } |