Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Fbada006 committed Jun 10, 2020
0 parents commit 7b587a0
Show file tree
Hide file tree
Showing 48 changed files with 1,326 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/ktlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Run KtLint

on:
push:
branches-ignore:
- 'master'

jobs:
ktlint:
runs-on: ubuntu-latest

steps:
- name: "checkout"
uses: actions/checkout@v2

- name: "ktlint"
uses: "vroy/gha-kotlin-linter@v1"
24 changes: 24 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Build Submission

on:
push:
branches-ignore:
- 'master'
- 'base'


jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build with Gradle
run: ./gradlew build
- name: Run Unit Tests
run: ./gradlew test
63 changes: 63 additions & 0 deletions .github/workflows/prepareZip.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: Prepare Code Challenge Zip

on:
push:
branches:
- 'base'

jobs:
build:
name: Build and test

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build with Gradle
run: ./gradlew build
- name: Run Unit Tests
run: ./gradlew test

zip:
name: Zip artifact

runs-on: ubuntu-latest

needs: build

steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Prepare artifact
run: git checkout -b candidate;
git branch -D base;
git remote set-url origin [email protected]:motain/android-code-challenge-submissions.git;

# INFO: We're archiving folder manually to keep file permissions.
# It's workaround to avoid file permissions change on artifact upload. More info: https://github.com/actions/upload-artifact/issues/38
# After actions/upload-artifact gets fix, this step should be avoided and 'path' value for upload-artifact shuld be changed to `path: ./`
- name: Zip artifact (workaround for upload-artifact permissions bug)
run: mkdir ../artifact;
cd ..;
zip -qq -r ./artifact/android-code-challenge-submissions.zip ./android-code-challenge-submissions;

- name: Upload artifact
uses: actions/[email protected]
with:
name: android-code-challenge-submissions
path: ../artifact

ktlint:
runs-on: ubuntu-latest

steps:
- name: "checkout"
uses: actions/checkout@v2

- name: "ktlint"
uses: "vroy/gha-kotlin-linter@v1"
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Project exclude paths
/.gradle/
2 changes: 2 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added .idea/caches/build_file_checksums.ser
Binary file not shown.
116 changes: 116 additions & 0 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 41 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Android Take Home Test

The purpose of this test is to evaluate your technical skills, communication and mindset.

You should exemplify the :muscle: best work you can do with the provided example and perhaps :boom: surprise us with your solution. You have *one* week time to work on the test, but our expectations are that a fraction of the time is needed for the test.

You are expected to refactor and improve the project to avoid the mistakes it has.

## Procedure

1. After completing the challenge, clean the project (builds, .gradle, etc). But remember: The project should still be runnable.
2. Compress project file as a ".zip" file.
3. Send the `zip` file back to the person you have been in contact with (from the recruiting team).
4. You will receive feedback for this project file which you sent us during the live interview.

Notes :
- Meaningful commit history (git) will be a plus.
- Feel free to add some comments or provide information in `README.md` file about things you would like to improve but didn't have time for this.
- The project zip file size should't be more 15 MB.

## Project

In this project, you will have a news feed activity. It retrieves the data from the local JSON file.
JSON is parsed manually and elements has been created from the parsed data.

All the logical operations are happening in `MyNewsActivity.kt` and the layout for the list items is
stored in `news_item.xml` file. There is only one data class for `News` element and it's in `model` folder.

The Application is written in Kotlin.

You are free to suggest and implement any library or code snippet that you think that is going to be useful
for the codebase. But please be sure to add detailed information about your suggestions and why they would be useful.

## Questions

Feel free to reach out to us if you have any issues or questions. You may contact the person that sent the
code challenge to you.

![](https://media.giphy.com/media/uADx98ByhpOwcE7KhW/giphy.gif)

:rocket: Have fun!
Loading

0 comments on commit 7b587a0

Please sign in to comment.