move folders etc, need to solve app import issue
8
app.json
@ -4,10 +4,10 @@
|
|||||||
"slug": "railbird-rn",
|
"slug": "railbird-rn",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"orientation": "portrait",
|
"orientation": "portrait",
|
||||||
"icon": "./assets/icon.png",
|
"icon": "./src/assets/icon.png",
|
||||||
"userInterfaceStyle": "light",
|
"userInterfaceStyle": "light",
|
||||||
"splash": {
|
"splash": {
|
||||||
"image": "./assets/splash.png",
|
"image": "./src/assets/splash.png",
|
||||||
"resizeMode": "contain",
|
"resizeMode": "contain",
|
||||||
"backgroundColor": "#ffffff"
|
"backgroundColor": "#ffffff"
|
||||||
},
|
},
|
||||||
@ -31,14 +31,14 @@
|
|||||||
},
|
},
|
||||||
"android": {
|
"android": {
|
||||||
"adaptiveIcon": {
|
"adaptiveIcon": {
|
||||||
"foregroundImage": "./assets/adaptive-icon.png",
|
"foregroundImage": "./src/assets/adaptive-icon.png",
|
||||||
"backgroundColor": "#ffffff"
|
"backgroundColor": "#ffffff"
|
||||||
},
|
},
|
||||||
"package": "android.railbird.app",
|
"package": "android.railbird.app",
|
||||||
"googleServicesFile": "./google-services.json"
|
"googleServicesFile": "./google-services.json"
|
||||||
},
|
},
|
||||||
"web": {
|
"web": {
|
||||||
"favicon": "./assets/favicon.png"
|
"favicon": "./src/assets/favicon.png"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
2
index.js
@ -1,6 +1,6 @@
|
|||||||
import { registerRootComponent } from "expo";
|
import { registerRootComponent } from "expo";
|
||||||
|
|
||||||
import App from "./App";
|
import App from "./src/App";
|
||||||
|
|
||||||
// registerRootComponent calls AppRegistry.registerComponent('main', () => App);
|
// registerRootComponent calls AppRegistry.registerComponent('main', () => App);
|
||||||
// It also ensures that whether you load the app in Expo Go or in a native build,
|
// It also ensures that whether you load the app in Expo Go or in a native build,
|
||||||
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
Before Width: | Height: | Size: 46 KiB After Width: | Height: | Size: 46 KiB |
@ -1,7 +1,7 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import { StyleSheet, View } from "react-native";
|
import { StyleSheet, View } from "react-native";
|
||||||
import BarGraph from "../component/charts/bar-graph/bar-graph";
|
import BarGraph from "../component/charts/bar-graph/bar-graph";
|
||||||
import { graph_data_two_measures } from "../mock/charts/mock-data";
|
import { graph_data_two_measures } from "../../mock/charts/mock-data";
|
||||||
|
|
||||||
// Session Mock - can be used for session summary screen using a query handler component
|
// Session Mock - can be used for session summary screen using a query handler component
|
||||||
// BarGraph component using mocked data currently
|
// BarGraph component using mocked data currently
|
@ -1,6 +1,6 @@
|
|||||||
import { render } from "@testing-library/react-native";
|
import { render } from "@testing-library/react-native";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import BarGraph from "../../component/charts/bar-graph/bar-graph";
|
import BarGraph from "../../src/component/charts/bar-graph/bar-graph";
|
||||||
import { graph_data_two_measures } from "../../mock/charts/mock-data";
|
import { graph_data_two_measures } from "../../mock/charts/mock-data";
|
||||||
|
|
||||||
describe("BarGraph Component Tests", () => {
|
describe("BarGraph Component Tests", () => {
|
||||||
|
@ -2,7 +2,7 @@ import "@testing-library/jest-native/extend-expect";
|
|||||||
import { render } from "@testing-library/react-native";
|
import { render } from "@testing-library/react-native";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
|
|
||||||
import ChartLabel from "../../component/charts/chart-label/chart-label";
|
import ChartLabel from "../../src/component/charts/chart-label/chart-label";
|
||||||
|
|
||||||
describe("ChartLabel Component Tests", () => {
|
describe("ChartLabel Component Tests", () => {
|
||||||
const mockData = {
|
const mockData = {
|
||||||
|
@ -3,7 +3,7 @@ import { render } from "@testing-library/react-native";
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import { Text } from "react-native";
|
import { Text } from "react-native";
|
||||||
|
|
||||||
import ChartView from "../../component/charts/chart-view";
|
import ChartView from "../../src/component/charts/chart-view";
|
||||||
|
|
||||||
describe("ChartView Component Tests", () => {
|
describe("ChartView Component Tests", () => {
|
||||||
it("applies the passed style prop correctly", () => {
|
it("applies the passed style prop correctly", () => {
|
||||||
|
@ -6,8 +6,8 @@ import React from "react";
|
|||||||
import {
|
import {
|
||||||
calculateBarOrigin,
|
calculateBarOrigin,
|
||||||
drawBarPath,
|
drawBarPath,
|
||||||
} from "../../component/charts/custom-bar-utils";
|
} from "../../src/component/charts/custom-bar-utils";
|
||||||
import { CustomBars } from "../../component/charts/custom-bars";
|
import { CustomBars } from "../../src/component/charts/custom-bars";
|
||||||
|
|
||||||
const mockYScaleFunction = scale.scaleLinear();
|
const mockYScaleFunction = scale.scaleLinear();
|
||||||
const mockXScaleFunction = scale.scaleBand();
|
const mockXScaleFunction = scale.scaleBand();
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { render } from "@testing-library/react-native";
|
import { render } from "@testing-library/react-native";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import LineGraph from "../../component/charts/line-graph/line-graph";
|
import LineGraph from "../../src/component/charts/line-graph/line-graph";
|
||||||
import { line_chart_two_y_data } from "../../mock/charts/mock-data";
|
import { line_chart_two_y_data } from "../../mock/charts/mock-data";
|
||||||
|
|
||||||
describe("LineGraph Component Tests", () => {
|
describe("LineGraph Component Tests", () => {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { renderHook } from "@testing-library/react-native";
|
import { renderHook } from "@testing-library/react-native";
|
||||||
import { GraphData, GraphProps } from "../../component/charts/graph-types";
|
import { GraphData, GraphProps } from "../../src/component/charts/graph-types";
|
||||||
import { useGraphData } from "../../component/charts/use-graph-data";
|
import { useGraphData } from "../../src/component/charts/use-graph-data";
|
||||||
|
|
||||||
describe("useGraphData", () => {
|
describe("useGraphData", () => {
|
||||||
it("should return correctly processed data from convertToGraphData", () => {
|
it("should return correctly processed data from convertToGraphData", () => {
|
||||||
|
@ -3,7 +3,7 @@ import "@testing-library/jest-native/extend-expect";
|
|||||||
import { cleanup, render, waitFor } from "@testing-library/react-native";
|
import { cleanup, render, waitFor } from "@testing-library/react-native";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { Text } from "react-native";
|
import { Text } from "react-native";
|
||||||
import withQueryHandling from "../../component/with-query-handling";
|
import withQueryHandling from "../../src/component/with-query-handling";
|
||||||
|
|
||||||
jest.mock("@apollo/client", () => ({
|
jest.mock("@apollo/client", () => ({
|
||||||
...jest.requireActual("@apollo/client"),
|
...jest.requireActual("@apollo/client"),
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { createAndFilter, createRangeFilter } from "../../graphql/filter";
|
import { createAndFilter, createRangeFilter } from "../../src/graphql/filter";
|
||||||
|
|
||||||
describe("create filterInput", () => {
|
describe("create filterInput", () => {
|
||||||
it("should create a filter input with the correct structure", () => {
|
it("should create a filter input with the correct structure", () => {
|
||||||
|