Skip to content
This repository has been archived by the owner on Jul 8, 2024. It is now read-only.

Create Javascript tests #90

Merged
merged 41 commits into from
Jun 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
fef8e48
Init test project
MaxStalker May 13, 2021
0d7b0ce
Add editor config
MaxStalker May 13, 2021
fa1177b
Add jest and babel config
MaxStalker May 13, 2021
9ec722b
Create Emulator class
MaxStalker May 13, 2021
ca1d570
Init flow.json for emulator
MaxStalker May 13, 2021
78c417c
Add package-lock
MaxStalker May 13, 2021
5be9080
Scaffold tests for available contracts and scripts
MaxStalker May 13, 2021
ffa340b
More Kibble tests
MaxStalker May 14, 2021
e5a9012
Add setup registry account instruction
MaxStalker May 14, 2021
f79544f
More tests. Refactor common methods into separate files
MaxStalker May 17, 2021
de221cf
Finish KittyItems tests
MaxStalker May 18, 2021
6657b1e
Start kitty-items-marketplace tests
MaxStalker May 19, 2021
ed31431
Rephrase test name
MaxStalker May 19, 2021
e44a35c
Add another item type
MaxStalker May 19, 2021
263ae39
Finish marketplace tests
MaxStalker May 19, 2021
1fc748a
Add docstrings
MaxStalker May 19, 2021
0053607
Add more documentation.Fix wording
MaxStalker May 19, 2021
35b8376
Add methods to simplify error handling
MaxStalker May 19, 2021
94f14ef
Refactor tests with error handling methods
MaxStalker May 19, 2021
da0e876
Add more refactoring and docstrings
MaxStalker May 19, 2021
3368ce0
Update test instructions to run tests one after another
MaxStalker May 19, 2021
c25c873
Add more docstrings
MaxStalker May 19, 2021
2c70400
Refactor code to use emulator port
MaxStalker May 19, 2021
3777749
Remove IntelliJ specific config lines
MaxStalker May 20, 2021
58b0250
Remove logging. Rephrase test names.
MaxStalker May 20, 2021
9c5eaff
Return result of the transaction or script execution
MaxStalker May 20, 2021
b6b3ff2
Add basic README
MaxStalker May 20, 2021
e0ef906
Delete package files in the root of the repo
MaxStalker May 20, 2021
be13ad5
Refactor using new release of testing framework
MaxStalker May 24, 2021
ee58350
Refactor code with js-testing updates
MaxStalker Jun 3, 2021
4b9de7e
Remove emulator and unused methods
MaxStalker Jun 2, 2021
087837b
Update jest timeout to a higher number
MaxStalker Jun 2, 2021
0c0240f
Update flow-js-testing version
MaxStalker Jun 8, 2021
f8adec0
Update title
MaxStalker Jun 10, 2021
8f0331e
Add new line at the end of the document
MaxStalker Jun 10, 2021
5084e76
Use default FungibleToken contract
MaxStalker Jun 10, 2021
e0ac82b
Refactor wording. Use KittyAdmin instead of Registry reference
MaxStalker Jun 10, 2021
6988a22
Fix wording
MaxStalker Jun 10, 2021
d5875d7
Prettify
MaxStalker Jun 10, 2021
963a352
Fix jsdoc definitions
MaxStalker Jun 10, 2021
4c2b22c
Refactor with simplified interactions
MaxStalker Jun 10, 2021
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
10 changes: 10 additions & 0 deletions cadence/lib/js/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = tab
insert_final_newline = false
max_line_length = 120
tab_width = 2
3 changes: 3 additions & 0 deletions cadence/lib/js/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Kitty Items Test Suit
Tests here were created with [JS Testing Framework](https://github.com/onflow/flow-js-testing).
If you ever get stuck, follow the link to find documentation and examples on how to use said framework.
12 changes: 12 additions & 0 deletions cadence/lib/js/babel.config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"presets": [
[
"@babel/preset-env",
{
"targets": {
"node": "current"
}
}
]
]
}
21 changes: 21 additions & 0 deletions cadence/lib/js/flow.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
MaxStalker marked this conversation as resolved.
Show resolved Hide resolved
"emulators": {
"default": {
"port": 3569,
"serviceAccount": "emulator-account"
}
},
"contracts": {},
"networks": {
"emulator": "127.0.0.1:3569",
"mainnet": "access.mainnet.nodes.onflow.org:9000",
"testnet": "access.devnet.nodes.onflow.org:9000"
},
"accounts": {
"emulator-account": {
"address": "f8d6e0586b0a20c7",
"keys": "8e3983030d2af1fa01c078241ad7f699d492e0239247f38d5a96cb959e436531"
}
},
"deployments": {}
}
5 changes: 5 additions & 0 deletions cadence/lib/js/jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module.exports = {
testEnvironment: "node",
verbose: true,
coveragePathIgnorePatterns: ["/node_modules/"],
};
Loading