Skip to content

Instantly share code, notes, and snippets.

View rainerhahnekamp's full-sized avatar

Rainer Hahnekamp rainerhahnekamp

View GitHub Profile
@rainerhahnekamp
rainerhahnekamp / Readme.md
Last active January 23, 2017 22:06
docker-compose.yml for sentry with version 2

This is an example for running sentry in docker-compose version 2.

Don't forget to initialize your database. Best way:

docker-compose exec sentry sentry upgrade
describe("Home", () => {
it("should click the button", () => {
cy.visit("");
cy.get("button").click();
cy.get("div.message").should("contain.text", "You clicked me");
})
})
it("should add a customer", () => {
cy.visit("");
cy.get("a").contains("Customers").click();
cy.get("a").contains("Add Customer").click();
})
<a data-test="btn-customers" mat-raised-button routerLink="/customer">Customers</a>
<a [routerLink]="['.', 'new']" color="primary" data-test="btn-customers-add" mat-raised-button>Add Customer</a>
it("should click on add customers", () => {
cy.visit("");
cy.get("[data-test=btn-customers]").click();
cy.get("[data-test=btn-customers-add]").click();
})
it('should click on add customers', () => {
cy.visit('')
.then(() => cy.get('[data-test=btn-customers]'))
.then((button) => button.click())
.then(() => cy.get('[data-test=btn-customers-add]'))
.then((button) => button.click());
});
it('should click on add customers', async () => {
await cy.visit('');
it('should fail', () => {
let isSuccessful = false;
cy.visit('');
cy.get('button').click();
cy.get('div.message').then(() => {
isSuccessful = true;
});
if (!isSuccessful) {
throw new Error('something is not working');
export interface Customer {
id: number;
firstname: string;
name: string;
country: string;
birthdate: string;
}
export const customerFeatureKey = 'Customer';
export interface State {customers: Customer[]}
export interface CustomerAppState {
[customerFeatureKey]: State;
}
export const initialState: State = {customers: []};
@Injectable()
export class CustomerEffects {
private baseUrl = 'https://local.eternal.com/api/customer';
constructor(
private actions$: Actions,
private http: HttpClient,
private router: Router
) {}
loadCustomers$ = createEffect(() =>