Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelomorgado authored and Matias Seijas committed Feb 15, 2019
1 parent 3310263 commit 6cc6b82
Show file tree
Hide file tree
Showing 14 changed files with 305 additions and 0 deletions.
15 changes: 15 additions & 0 deletions demo/screens/EthereumQuestion.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import EthereumQuestion from "./EthereumQuestion";

describe("EthereumQuestion", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<EthereumQuestion />)).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions demo/screens/EthereumSignIn.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import EthereumSignIn from "./EthereumSignIn";

describe("EthereumSignIn", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<EthereumSignIn />)).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions demo/screens/EthereumSignUp.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import EthereumSignUp from "./EthereumSignUp";

describe("EthereumSignUp", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<EthereumSignUp />)).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions demo/screens/Home.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import Home from "./Home";

describe("Home", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<Home />)).toMatchSnapshot();
});
});
16 changes: 16 additions & 0 deletions demo/screens/LandClaim.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import LandClaim from "./LandClaim";

describe("LandClaim", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
const navigation = { getParam: jest.fn() };
expect(shallow(<LandClaim navigation={navigation} />)).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions demo/screens/ListLands.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import ListLands from "./ListLands";

describe("EthereumQuestion", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<ListLands />)).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions demo/screens/OnboardingHome.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from "react";
import NavigationTestUtils from "react-navigation/NavigationTestUtils";
import { shallow } from "enzyme";
import OnboardingHome from "./OnboardingHome";

describe("OnboardingHome", () => {
jest.useFakeTimers();
beforeEach(() => {
NavigationTestUtils.resetInternalState();
});

it("renders the component", async () => {
expect(shallow(<OnboardingHome />)).toMatchSnapshot();
});
});
44 changes: 44 additions & 0 deletions demo/screens/__snapshots__/EthereumQuestion.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`EthereumQuestion renders the component 1`] = `
<Component
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<LargeText>
Are you new to Ethereum?
</LargeText>
<Component
style={
Object {
"flexDirection": "row",
"marginTop": 20,
}
}
>
<Button
onPress={[Function]}
title="Yep"
/>
</Component>
<Component
style={
Object {
"flexDirection": "row",
"marginTop": 20,
}
}
>
<Button
onPress={[Function]}
title="Nope"
/>
</Component>
</Component>
`;
31 changes: 31 additions & 0 deletions demo/screens/__snapshots__/EthereumSignIn.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`EthereumSignIn renders the component 1`] = `
<Component
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<LargeText>
Cool. Let's start by hooking this app with your wallet.
</LargeText>
<Component
style={
Object {
"flexDirection": "row",
"marginTop": 30,
}
}
>
<Button
onPress={[Function]}
title="Connect with WalletConnect"
/>
</Component>
</Component>
`;
22 changes: 22 additions & 0 deletions demo/screens/__snapshots__/EthereumSignUp.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`EthereumSignUp renders the component 1`] = `
<KeyboardAvoidingView
behavior="padding"
enabled={true}
keyboardVerticalOffset={84}
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<LargeText>
Cool. Let's start by picking your Tasit username.
</LargeText>
<EthereumSignUpForm />
</KeyboardAvoidingView>
`;
25 changes: 25 additions & 0 deletions demo/screens/__snapshots__/Home.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`Home renders the component 1`] = `
<Component
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<Component
source={1}
/>
<LargeText>
Tasit
</LargeText>
<Button
onPress={[Function]}
title="Decentraland"
/>
</Component>
`;
29 changes: 29 additions & 0 deletions demo/screens/__snapshots__/LandClaim.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`LandClaim renders the component 1`] = `
<Component
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<Land />
<Component
style={
Object {
"flexDirection": "row",
"marginTop": 30,
}
}
>
<Button
onPress={[Function]}
title="Claim"
/>
</Component>
</Component>
`;
14 changes: 14 additions & 0 deletions demo/screens/__snapshots__/ListLands.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`EthereumQuestion renders the component 1`] = `
<ListViewMock
renderRow={[Function]}
renderScrollComponent={[MockFunction]}
style={
Object {
"backgroundColor": "#fff",
"flex": 1,
}
}
/>
`;
34 changes: 34 additions & 0 deletions demo/screens/__snapshots__/OnboardingHome.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`OnboardingHome renders the component 1`] = `
<Component
style={
Object {
"alignItems": "center",
"backgroundColor": "#fff",
"flex": 1,
"justifyContent": "center",
}
}
>
<Component
source={1}
/>
<LargeText>
Let's get you set up with a secure way to store this land!
</LargeText>
<Component
style={
Object {
"flexDirection": "row",
"marginTop": 30,
}
}
>
<Button
onPress={[Function]}
title="Get started"
/>
</Component>
</Component>
`;

0 comments on commit 6cc6b82

Please sign in to comment.