Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
126 commits
Select commit Hold shift + click to select a range
3a00220
make the example code a buildable project
fulformc May 10, 2024
6a82309
add a development guide
fulformc May 10, 2024
0dfce07
UI now adjust accordingly if it's dark mode
aurvyn May 29, 2024
5d9bfbd
fixed colors on force dark mode
aurvyn May 29, 2024
fc6a50d
Added 3 examples using theme options
aurvyn May 29, 2024
ae0d9f1
Added `theme` to the Props section
aurvyn May 29, 2024
2fda76b
Removed the functionality to force light/dark mode
aurvyn May 29, 2024
154ab06
remove starter README file from example app
fulformc May 29, 2024
cc84c99
Merge pull request #6 from rhventures/fulformc/development-build-process
rhit-jungh May 29, 2024
1088b81
Dropdown arrow now uses unicode instead of png
aurvyn May 29, 2024
887435f
Removed unused imports
aurvyn May 29, 2024
c8dc640
MultiSelect: Replaced commas with highlights
aurvyn May 30, 2024
a4fe1e8
The default text is no longer highlighted
aurvyn May 30, 2024
4a58466
Removed unnecessary StyleSheet.flatten calls
aurvyn May 30, 2024
b16953a
added transparency to arrow background
aurvyn May 30, 2024
d1f7181
Darkmode bugfix (#7)
aurvyn Jun 3, 2024
2513b85
Doc Updates (#10)
aurvyn Jun 3, 2024
6e9c9df
MultiSelect UI enhancement (#8)
aurvyn Jun 5, 2024
c3f902d
re commit after removing apk
rhit-jungh Jun 5, 2024
abd095e
Integration with scrolls working with top selector
rhit-jungh Jun 5, 2024
c878c53
Integration test cases refactored
rhit-jungh Jun 5, 2024
23b60e9
singleSelectIntegration refactored
rhit-jungh Jun 5, 2024
2f174d0
change of file name
rhit-jungh Jun 5, 2024
d50804e
single integration test complete
rhit-jungh Jun 5, 2024
2dc3c1b
scroll and multi select integration
rhit-jungh Jun 6, 2024
db89ee0
dynamic display check test
rhit-jungh Jun 6, 2024
8e80473
MultiSelect Extend Overflow (#9)
aurvyn Jun 6, 2024
98ff42f
dynamic scrolling test functional
rhit-jungh Jun 6, 2024
3e213fd
Dynamic Testing Functional
rhit-jungh Jun 7, 2024
d043b11
Test file names changed
rhit-jungh Jun 7, 2024
2fef207
System Algorithm test
rhit-jungh Jun 7, 2024
bf62ecd
starting documentation
rhit-jungh Jun 7, 2024
5d972b1
check
rhit-jungh Jun 7, 2024
c6b07f7
hyperlink
rhit-jungh Jun 7, 2024
e35e9d2
Documentation Check
rhit-jungh Jun 7, 2024
54c6dc5
documentation check
rhit-jungh Jun 7, 2024
3157ab3
generating debug app
rhit-jungh Jun 7, 2024
2c342f6
doc check
rhit-jungh Jun 7, 2024
c813683
Documentation image testing
rhit-jungh Jun 7, 2024
57ad828
WDIO config docs
rhit-jungh Jun 7, 2024
4cd0264
file config docs
rhit-jungh Jun 7, 2024
d24e7ce
doc check
rhit-jungh Jun 7, 2024
14a2302
doc check
rhit-jungh Jun 7, 2024
ce0f10f
doc check
rhit-jungh Jun 7, 2024
79dc5fe
doc check
rhit-jungh Jun 7, 2024
bbf8636
doc check
rhit-jungh Jun 7, 2024
dafbb79
Appium Inspector set up docs
rhit-jungh Jun 7, 2024
5371257
Appium Inspector Docs
rhit-jungh Jun 7, 2024
72df414
Doc Check
rhit-jungh Jun 7, 2024
0716d55
doc check
rhit-jungh Jun 7, 2024
dd86242
Using Appium Inspector Documentation
rhit-jungh Jun 7, 2024
0166fe3
Docs done for set up
rhit-jungh Jun 7, 2024
021a482
doc edits
rhit-jungh Jun 7, 2024
97414b1
change
rhit-jungh Jun 10, 2024
8e762fb
ios test start
rhit-jungh Jun 10, 2024
f78ad3b
configs changed
rhit-jungh Jun 10, 2024
c011344
connection success
rhit-jungh Jun 10, 2024
d867d34
Update README.md
rhit-jungh Jun 10, 2024
f33d99c
connects to the wdio
rhit-jungh Jun 10, 2024
ed93f0f
first test for ios passes
rhit-jungh Jun 10, 2024
3938fbd
Merge branch 'GUI-Testing' of https://github.com/rhventures/react-nat…
rhit-jungh Jun 10, 2024
6b4d261
single select for top bar in iOS testing passes
rhit-jungh Jun 11, 2024
1cefc7a
update docs
rhit-jungh Jun 11, 2024
9c2682a
MultiSelect Split on Comma Bugfix (#12)
aurvyn Jun 11, 2024
40dd73d
unit test for the small bar passes
rhit-jungh Jun 11, 2024
aff86b6
multi select test passes
rhit-jungh Jun 11, 2024
079c1e4
scroll and select for single select passes
rhit-jungh Jun 11, 2024
e41eedd
Integration Single Select Refactored
rhit-jungh Jun 11, 2024
df65f04
scroll and select functional for ios Testing
rhit-jungh Jun 11, 2024
2dabc74
Integration testing for multi select passes
rhit-jungh Jun 11, 2024
f8b9b7c
documentations for iOS testing
rhit-jungh Jun 11, 2024
22af802
update ReadMe Docs
rhit-jungh Jun 11, 2024
7054b0c
update doc image
rhit-jungh Jun 11, 2024
e58bbd8
Inherit Custom Styles (#13)
aurvyn Jun 11, 2024
0e71948
starting Dynamics testing
rhit-jungh Jun 11, 2024
1a46a2f
dynamic select test functiona;
rhit-jungh Jun 12, 2024
92bc97c
Dynamic Select Test Complete
rhit-jungh Jun 12, 2024
2d22096
Algorithm Test functional
rhit-jungh Jun 12, 2024
6514ec5
System Algorithm Test Complete
rhit-jungh Jun 12, 2024
81a00e1
edits
rhit-jungh Jun 12, 2024
48f6072
edits
rhit-jungh Jun 12, 2024
aca8b44
Doc update
rhit-jungh Jun 12, 2024
781fe84
edit
rhit-jungh Jun 12, 2024
64b0897
Merge pull request #24 from rhventures/iOS_testing
rhit-jungh Jun 12, 2024
2967818
Merge branch 'main' of https://github.com/rhventures/react-native-dro…
rhit-jungh Jun 12, 2024
526a524
mutation killed after pull
rhit-jungh Jun 12, 2024
5e97c21
mutant killed for Dynamic testing
rhit-jungh Jun 12, 2024
6a69fe6
mutant killed for multi-select testing
rhit-jungh Jun 12, 2024
ceaf5b5
Mutant killed for single Select
rhit-jungh Jun 12, 2024
2a8b7a0
Branched from #22
aurvyn Jun 12, 2024
36162bc
update read me
rhit-jungh Jun 12, 2024
d527b33
Allow `disabled` to be passed in
aurvyn Jun 12, 2024
fe16638
Disable selector box if true
aurvyn Jun 12, 2024
7f40d0f
Change appearance if disabled
aurvyn Jun 12, 2024
c328a24
docs fixed
rhit-jungh Jun 13, 2024
b04d2d5
fix documentation
rhit-jungh Jun 13, 2024
867edb6
documentation update
rhit-jungh Jun 13, 2024
954aa72
Doc Upate
rhit-jungh Jun 13, 2024
1396735
documentation update
rhit-jungh Jun 13, 2024
0b0deba
documentation update
rhit-jungh Jun 13, 2024
e9900b8
documtation update
rhit-jungh Jun 13, 2024
b807504
documentaion update
rhit-jungh Jun 13, 2024
d477952
fix read me
rhit-jungh Jun 13, 2024
f474fad
Fix Both Read Mes
rhit-jungh Jun 13, 2024
73a85cd
doc update
rhit-jungh Jun 13, 2024
489456b
Update from parent branch
aurvyn Jun 13, 2024
37c7d46
update from parent branch
aurvyn Jun 13, 2024
fdba11f
Merge branch 'dysrakescence/disable-selectors' of https://github.com/…
rhit-jungh Jun 13, 2024
cafde82
no test broken after pull
rhit-jungh Jun 13, 2024
817deac
Change file name
rhit-jungh Jun 13, 2024
7d52b75
Double Render Bugfix (#14)
aurvyn Jun 14, 2024
800a9e0
Code Refactor (#15)
aurvyn Jun 18, 2024
5cf81ee
MultiSelect Clear Button (#17)
aurvyn Jun 21, 2024
6724b89
MultiSelect Clear Button Styling (#18)
aurvyn Jun 21, 2024
d1aa6d1
Merge branch 'main' into GUI-Testing
rhit-jungh Jun 24, 2024
6c33867
Update README.md
rhit-jungh Jun 24, 2024
93d1e44
iOS Integration (#16)
aurvyn Jun 24, 2024
ec310a3
Merge branch 'main' into GUI-Testing
rhit-jungh Jun 24, 2024
3386e0d
Update README.md
rhit-jungh Jun 24, 2024
d36ce10
Merge branch 'main' of https://github.com/rhventures/react-native-dro…
rhit-jungh Aug 26, 2024
0edb8c0
change package json
rhit-jungh Aug 26, 2024
1f9c8b2
Merge branch 'main' of https://github.com/rhventures/react-native-dro…
rhit-jungh Aug 26, 2024
a4b196b
fix package json and reinstall NPM
rhit-jungh Aug 26, 2024
85a430e
fix breaking tests
rhit-jungh Aug 26, 2024
fc932cd
fix ios test build
rhit-jungh Aug 27, 2024
0957e96
remove unnecessary comments
rhit-jungh Aug 28, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -62,4 +62,6 @@ yarn-error.log
# Temporary files created by Metro to check the health of the file watcher
.metro-health-check*

react-native-dropdown-selector-*.tgz
react-native-dropdown-selector-*.tgz

.apk
Binary file added Test-DropDown-Selector-iOS/AInspector.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Test-DropDown-Selector-iOS/Hierarchy.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
229 changes: 229 additions & 0 deletions Test-DropDown-Selector-iOS/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,229 @@
# Using APPIUM and APPIUM Inspector for React Native GUI testing on iOS Applications

## Why APPIUM?
Well... Selenium does not support mobile apps for test yet... Appium can not only be used for testing web apps, but it can also be used for testing iOS, Android or Watch OS such as Tizen.

If you would like to know more information about Appium Software, here is the URL:
https://appium.io/docs/en/latest/intro/

## *We are only testing on iOS Platform on Mac OS at this time*

## General Prerequisites for using APPIUM

### Programming Proficiency
- Acceptable Knowledge in Javascript, Java, or Python.

### Install Node.JS
- https://nodejs.org/en

## iOS Setup
1. Install Xcode from the MacOS App Store.
2. Install Xcode Command Line Tools:
```
xcode-select --install
```
- to make sure it is installed:
```
xcode-select -p
```

### Install Appium Inspector
- [Download the compatable Appium Inspector here](https://github.com/appium/appium-inspector/releases)
Copy link

Copilot AI Mar 26, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word 'compatable' is misspelled; it should be 'compatible'.

Suggested change
- [Download the compatable Appium Inspector here](https://github.com/appium/appium-inspector/releases)
- [Download the compatible Appium Inspector here](https://github.com/appium/appium-inspector/releases)

Copilot uses AI. Check for mistakes.
- I used the mac.arm64.exe
- *When using a macbook, make sure to know if your mac supports x64 or arm 64!*

### Install Appium
- [Appium](https://appium.io/docs/en/latest/quickstart/install/)
or run this command in your terminal:
```
npm install -g appium
```
Check your appium version using
```
appium -v
```
### Execute Appium Doctor
For Appium to work, the necessary downloads must be checked.
run:
```
npm install appium-doctor -g
```
and then run:
```
appium-doctor
```
- If there is necessary fix that must be done, it must be done. For optional fixes, it can be ignored.

### Install Appium Drivers
We will use a driver for the Appium to function properly. Run:
```
appium driver install xcuitest
```
You can check the installed drivers using:
```
appium driver list
```

## Generating a debug app to test.
If you already have the app as an ipa file, then you can skip this step

### Using React-Native
**If you do not have an ipa file of your app :**
- go to [React Native Set Up](https://reactnative.dev/docs/set-up-your-environment) and follow the instructions to integrate with the existing app you have through [Integration w/ Existing Apps](https://reactnative.dev/docs/integration-with-existing-apps)
- After you have successfully integrated your app with with React Native, you should have brew installed. Now go ahead and install the dependency Carthage
```
brew install carthage
```
- now proceed to the next step.


### Generating the debug app
- Once you run the command at the proper directory:
```
npm run ios
```
- you will get something like:
```
Installing "/path/to/your/debug/app/example.app"
```
- This will be your app path. **REMEMBER THIS PATH!**

## Setup the WebDriverIO
- Create a new folder named like "Test-<'CustomName'> under your root project directory
- My folder heirarchy looks like:
- ![alt text](Hierarchy.png)
- In my case, it would be the **Test-DropDown-Selector-iOS**
2. Run the following command in the new folder you just created
```
npm init wdio
```
This will trigger the installation process. Now move on to the configurations
### Configurations
- **Project name**: Assuming you are in the right folder...: Yes
- **E2E Testing**
- **Where**: On my local machine
- **Mobile** - native, hybrid and mobile web apps ... -> If its a web application, choose Web
- **iOS** : Mobile Environment
- **Framework**: I used Mocha, but feel free to use what you need
- No Compiler
- No autogenerate
- **Reporter**: **spec**
- **Plugins**: NONE. Just press Enter
- **Visual testing**: Default. Just Press Enter
- **Add a service**: Appium
- Run npm install
- Continue with Appium setup using appium-installer?: NO

## Configure your wdio.config.js file
There should be a **wdio.conf.js** file generated in the testing folder you previously created

Now in create a folder named **test** in newly made testing folder. This is where all the test files will go.
Anything not mentioned here can be left as default

- **Port** : 4723
- **Specs** : this is where your test files go. If your test file name is **HelloWorld.js**, then the snippet might look like:
```
specs : [
'./test/HelloWorld.js'
]

```
- **Max Instances** : Read the description this can change based on test environment.
- **Capabilities**: *This can change based on your development settings.*
- **platformName**: iOS
- **BrowserName** : *Delete this line, we are not using a browser driver*
- **appium:deviceName**: The emulator name you are using. Check iOS Simulator
- **appium:platformVersion**: Check your iOS Simulator
- **appium:automationName**: = XCUItest
- **appium:app**: the path to the debug app you generated earlier.

My code snippet looks like:
```
capabilities: [{
// capabilities for local Appium web tests on iOS
platformName: 'iOS',
'appium:deviceName': 'iPhone 15 Pro',
'appium:platformVersion': '17.5',
'appium:automationName': 'XCUITest',
'appium:app' : iosAppPath
}],
```
- **framework** : Since I choose Mocha, I have it as *Mocha*, However, make sure this matches the testing framework you choose
- **mochaOpts** : the timeout here sets the time limit on the test case.
- I set mine to :
```
mochaOpts: {
ui: 'bdd',
timeout: 60000
},
```
- Remaning can be left default

- Now install Appium in your testing folder, **not the "test" folder**
```
npm install --save-dev appium@next
```

## Setting up your Appium Inspector
1. Open your Appium Inspector you installed earlier.
2. go to Appium Inspector Tab, configure your boxes:

- **Remote Host** : default. -> Mine is 127.0.0.1
- **Remote Port** : Set it to some number besides 4723. Mine is 3000
- **Remote Path** : default. -> Mine is /

3. Now in the JSON Representation Tab, copy the **Capabilities** code snippet from *wdio.conf.js* file and paste it.
4. *platformName* should also be in quotes.* Click save
5. Your capacity builder should be filled. If it is not automatically filled, it must be manually filled.
6. Now in the capacity builder, make sure all the middle boxes are showing *text*
7. Save the capability set

- After everything, your set up should look similar to this:
- ![alt text](AInspector.png)
8. Leave the Inspector open for the Next Step

### Connect your Appium Inspector with your app
1. Open up terminal.
2. Run this snippet in your terminal, with the *<'Port Number'>* being your number from the **Remote Port** number from Appium Inspector Setup:
```
appium -p <Port Number>
```
3. Now the server for appium inspector should be running
4. **Make sure your simulator is up and running.**
5. **Make sure the app is running on the simulator-> run this command at your ios directory**
```
npm run ios
```
6. Now click **Start Session** in the bottom right corner.
7. If it connects, congradulations! Move on to the next section.


# Using the APPIUM Inspector
**GO WATCH:**
- [Tutorial](https://www.youtube.com/watch?v=Q5Oy8axA8Qw&t=1225s) start from 17:40
- There are much more ways to find elements and generate assertions through using appium inspector. Take a look at this [WebdriverIO Docs](https://webdriver.io/docs/api/browser)
- Now go and mess with test cases and see what is the most optimized method for your project.

### To Run the Test files
- Run:
```
npx wdio
```
### Important
- **The test cases for this project was built based on iPhone 15 Pro Frame.** To ensure all the test cases pass, make sure the simulator uses *iPhone 15 Pro.*

### Error Handling*
- If you run into an error: *"No spec files to run"*
- You do not have your test files specified in specs at *wdio.conf.js*

- If you run into an error: *"Connection Refuse error"*
- That means the server port is occupied. Run this command to kill all the active ports:
```
pkill -9 -f appium
```
- if you run into an error: *"ts-node/esm/trasnpile-only 'resolve' did not call the next hook.."*
- Running the following command will fix it.
```
npm i -D typescript ts-node
```

Loading