Merge pull request 'loewy/move-app-to-src' (#99) from loewy/move-app-to-src into master
Reviewed-on: railbird/railbird-mobile#99
4
App.tsx
@ -1,6 +1,6 @@
|
||||
import React, { useEffect } from "react";
|
||||
import { ClientProvider, useAuthHeader } from "./graphql/client";
|
||||
import AppNavigator from "./navigation/app-navigator";
|
||||
import { ClientProvider, useAuthHeader } from "./src/graphql/client";
|
||||
import AppNavigator from "./src/navigation/app-navigator";
|
||||
|
||||
import { DEV_USER_ID } from "@env";
|
||||
import AsyncStorage from "@react-native-async-storage/async-storage";
|
||||
|
8
app.json
@ -4,10 +4,10 @@
|
||||
"slug": "railbird-rn",
|
||||
"version": "1.0.0",
|
||||
"orientation": "portrait",
|
||||
"icon": "./assets/icon.png",
|
||||
"icon": "./src/assets/icon.png",
|
||||
"userInterfaceStyle": "light",
|
||||
"splash": {
|
||||
"image": "./assets/splash.png",
|
||||
"image": "./src/assets/splash.png",
|
||||
"resizeMode": "contain",
|
||||
"backgroundColor": "#ffffff"
|
||||
},
|
||||
@ -31,14 +31,14 @@
|
||||
},
|
||||
"android": {
|
||||
"adaptiveIcon": {
|
||||
"foregroundImage": "./assets/adaptive-icon.png",
|
||||
"foregroundImage": "./src/assets/adaptive-icon.png",
|
||||
"backgroundColor": "#ffffff"
|
||||
},
|
||||
"package": "android.railbird.app",
|
||||
"googleServicesFile": "./google-services.json"
|
||||
},
|
||||
"web": {
|
||||
"favicon": "./assets/favicon.png"
|
||||
"favicon": "./src/assets/favicon.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
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 { StyleSheet, View } from "react-native";
|
||||
import { graph_data_two_measures } from "../../test/mock/charts/mock-data";
|
||||
import BarGraph from "../component/charts/bar-graph/bar-graph";
|
||||
import { graph_data_two_measures } from "../mock/charts/mock-data";
|
||||
|
||||
// Session Mock - can be used for session summary screen using a query handler component
|
||||
// BarGraph component using mocked data currently
|
@ -1,7 +1,7 @@
|
||||
import { render } from "@testing-library/react-native";
|
||||
import React from "react";
|
||||
import BarGraph from "../../component/charts/bar-graph/bar-graph";
|
||||
import { graph_data_two_measures } from "../../mock/charts/mock-data";
|
||||
import BarGraph from "../../src/component/charts/bar-graph/bar-graph";
|
||||
import { graph_data_two_measures } from "../mock/charts/mock-data";
|
||||
|
||||
describe("BarGraph Component Tests", () => {
|
||||
it("renders correctly with data", () => {
|
||||
|
@ -2,7 +2,7 @@ import "@testing-library/jest-native/extend-expect";
|
||||
import { render } from "@testing-library/react-native";
|
||||
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", () => {
|
||||
const mockData = {
|
||||
|
@ -3,7 +3,7 @@ import { render } from "@testing-library/react-native";
|
||||
import React from "react";
|
||||
import { Text } from "react-native";
|
||||
|
||||
import ChartView from "../../component/charts/chart-view";
|
||||
import ChartView from "../../src/component/charts/chart-view";
|
||||
|
||||
describe("ChartView Component Tests", () => {
|
||||
it("applies the passed style prop correctly", () => {
|
||||
|
@ -6,8 +6,8 @@ import React from "react";
|
||||
import {
|
||||
calculateBarOrigin,
|
||||
drawBarPath,
|
||||
} from "../../component/charts/custom-bar-utils";
|
||||
import { CustomBars } from "../../component/charts/custom-bars";
|
||||
} from "../../src/component/charts/custom-bar-utils";
|
||||
import { CustomBars } from "../../src/component/charts/custom-bars";
|
||||
|
||||
const mockYScaleFunction = scale.scaleLinear();
|
||||
const mockXScaleFunction = scale.scaleBand();
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { render } from "@testing-library/react-native";
|
||||
import React from "react";
|
||||
import LineGraph from "../../component/charts/line-graph/line-graph";
|
||||
import { line_chart_two_y_data } from "../../mock/charts/mock-data";
|
||||
import LineGraph from "../../src/component/charts/line-graph/line-graph";
|
||||
import { line_chart_two_y_data } from "../mock/charts/mock-data";
|
||||
|
||||
describe("LineGraph Component Tests", () => {
|
||||
it("renders correctly with data", () => {
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { renderHook } from "@testing-library/react-native";
|
||||
import { GraphData, GraphProps } from "../../component/charts/graph-types";
|
||||
import { useGraphData } from "../../component/charts/use-graph-data";
|
||||
import { GraphData, GraphProps } from "../../src/component/charts/graph-types";
|
||||
import { useGraphData } from "../../src/component/charts/use-graph-data";
|
||||
|
||||
describe("useGraphData", () => {
|
||||
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 React from "react";
|
||||
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.requireActual("@apollo/client"),
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { createAndFilter, createRangeFilter } from "../../graphql/filter";
|
||||
import { createAndFilter, createRangeFilter } from "../../src/graphql/filter";
|
||||
|
||||
describe("create filterInput", () => {
|
||||
it("should create a filter input with the correct structure", () => {
|
||||
|