From 04344c6c8b1b1dbd607bf4d6246ecbc130b4d09b Mon Sep 17 00:00:00 2001 From: Oliver Date: Tue, 28 Sep 2021 23:26:10 +1000 Subject: [PATCH] Add a dummy .dsn file --- .github/workflows/lint.yaml | 33 ---------------- .github/workflows/test.yaml | 77 +++++++++++++++++++++++++++++++++++++ .gitignore | 2 + lib/dummy_dsn.dart | 3 ++ 4 files changed, 82 insertions(+), 33 deletions(-) delete mode 100644 .github/workflows/lint.yaml create mode 100644 .github/workflows/test.yaml create mode 100644 lib/dummy_dsn.dart diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml deleted file mode 100644 index 2233262c..00000000 --- a/.github/workflows/lint.yaml +++ /dev/null @@ -1,33 +0,0 @@ -# Run flutter linting checks - -name: linting - -on: - push: - branches: - - master - pull_request: - branches: - - master - -jobs: - - lint: - runs-on: ubuntu-latest - - steps: - - name: Checkout code - uses: actions/checkout@v2 - with: - submodules: recursive - - name: Setup Java - uses: actions/setup-java@v1 - with: - java-version: '12.x' - - name: Setup Flutter - uses: subosito/flutter-action@v1 - with: - flutter-version: '2.2.3' - - run: flutter pub get - - run: flutter analyze - \ No newline at end of file diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml new file mode 100644 index 00000000..e9a7030b --- /dev/null +++ b/.github/workflows/test.yaml @@ -0,0 +1,77 @@ +# Run flutter linting checks + +name: test + +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + + lint: + runs-on: ubuntu-latest + + env: + SENTRY_DSN: ${{ secrets.SENTRY_DSN }} + + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + submodules: recursive + - name: Setup Java + uses: actions/setup-java@v1 + with: + java-version: '12.x' + - name: Setup Flutter + uses: subosito/flutter-action@v1 + with: + flutter-version: '2.2.3' + - run: flutter pub get + - run: cp lib/dummy_dsn.dart lib/dsn.dart + - run: flutter analyze + - run: flutter test --coverage + + android: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + submodules: recursive + - name: Setup Java + uses: actions/setup-java@v1 + with: + java-version: '12.x' + - name: Setup Flutter + uses: subosito/flutter-action@v1 + with: + flutter-version: '2.2.3' + - run: flutter pub get + - run: cp lib/dummy_dsn.dart lib/dsn.dart + - run: flutter build apk + +ios: + runs-on: macos-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + submodules: recursive + - name: Setup Java + uses: actions/setup-java@v1 + with: + java-version: '12.x' + - name: Setup Flutter + uses: subosito/flutter-action@v1 + with: + flutter-version: '2.2.3' + - run: flutter pub get + - run: cp lib/dummy_dsn.dart lib/dsn.dart + - run: flutter build ios --release --no-codesign diff --git a/.gitignore b/.gitignore index 6c9c3b53..2604e33b 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,8 @@ .history .svn/ +coverage/* + # Sentry API key lib/dsn.dart diff --git a/lib/dummy_dsn.dart b/lib/dummy_dsn.dart new file mode 100644 index 00000000..d53bb6ff --- /dev/null +++ b/lib/dummy_dsn.dart @@ -0,0 +1,3 @@ +// Dummy DSN to use for unit testing, etc + +const String SENTRY_DSN_KEY = "https://12345678901234567890@abcdef.ingest.sentry.io/11223344"; \ No newline at end of file