Skip to content

Commit

Permalink
Tests fixed + API/Faucet/RPC Urls updated
Browse files Browse the repository at this point in the history
  • Loading branch information
TristanAllaire committed May 1, 2024
1 parent 970b52b commit 0b07515
Show file tree
Hide file tree
Showing 23 changed files with 40 additions and 38 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ mavkit-client originate contract counter \
--init 10 --burn-cap 0.1 --force
```

Again, you will receive several messages from the node and you should get the confirmation that the contract has been published. Note the `KT1...` address available in logs, you'll be able to find your contract onto an indexer like `mvkt` through url like `https://api.mavryk.io/basenet/v1/KT1.../` don't forget to put your `KT1` address
Again, you will receive several messages from the node and you should get the confirmation that the contract has been published. Note the `KT1...` address available in logs, you'll be able to find your contract onto an indexer like `mvkt` through url like `https://basenet.api.mavryk.network/v1/KT1.../` don't forget to put your `KT1` address

You can know call your contract with

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ mavkit-client originate contract counter \
--init 10 --burn-cap 0.1 --force
```

Again, you will receive several messages from the node and you should get the confirmation that the contract has been published. Note the `KT1...` address available in logs, you'll be able to find your contract onto an indexer like `mvkt` through url like `https://api.mavryk.io/basenet/v1/KT1.../` don't forget to put your `KT1` address
Again, you will receive several messages from the node and you should get the confirmation that the contract has been published. Note the `KT1...` address available in logs, you'll be able to find your contract onto an indexer like `mvkt` through url like `https://basenet.api.mavryk.network/v1/KT1.../` don't forget to put your `KT1` address

You can know call your contract with

Expand Down
16 changes: 9 additions & 7 deletions src/bin/expect_tests/contract_metadata.ml
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ let%expect_test _ =
[%expect
{|
(Pair 42
{ Elt "" 0x74657a6f732d73746f726167653a68656c6c6f253246776f726c64 ;
{ Elt "" 0x6d617672796b2d73746f726167653a68656c6c6f253246776f726c64 ;
Elt "hello/world"
0x207b0a2020226e616d65223a22464132204e4654204d61726b6574706c616365222c0a2020226465736372697074696f6e223a224578616d706c65206f662046413220696d706c656d656e746174696f6e222c0a20202276657273696f6e223a22302e302e31222c0a2020226c6963656e7365223a7b226e616d65223a224d4954227d2c0a202022617574686f7273223a5b224d617269676f6c643c636f6e74616374406d617269676f6c642e6465763e225d2c0a202022686f6d6570616765223a2268747470733a2f2f6d617269676f6c642e646576222c0a202022736f75726365223a7b0a202022746f6f6c73223a5b224c69676f225d2c0a2020226c6f636174696f6e223a2268747470733a2f2f6769746875622e636f6d2f6c69676f6c616e672f636f6e74726163742d636174616c6f6775652f747265652f6d61696e2f6c69622f666132227d2c0a202022696e7465726661636573223a5b22545a49502d303132225d2c0a2020226572726f7273223a205b5d2c0a2020227669657773223a205b0a202020207b0a202020202020226e616d65223a20226765742d616c6c6f77616e63652d666f722d75736572222c0a202020202020226465736372697074696f6e223a2022476574207468652063757272656e7420616c6c6f77616e636520666f7220612075736572206f662074686520636f6e74726163742e222c0a2020202020202270757265223a202274727565222c0a20202020202022696d706c656d656e746174696f6e73223a205b0a2020202020202020207b20226d696368656c736f6e53746f726167655669657722203a207b22706172616d65746572223a7b227072696d223a22696e74227d2c2272657475726e54797065223a7b227072696d223a22696e74227d2c22636f6465223a5b7b227072696d223a22554e50414952227d2c7b227072696d223a2253574150227d2c7b227072696d223a22434152227d2c7b227072696d223a22414444227d5d7d207d0a20202020202020205d0a202020207d0a202020205d0a20207d0a2020 }) |}];
run_ligo_good
Expand Down Expand Up @@ -342,7 +342,7 @@ let%expect_test _ =
{|
(Pair 42
{ Elt ""
0x7368613235363a2f2f3078316637633766646533393162633436613238636439386137373733336662653539323731393064626535343933666538313234346565323964633632343537372f74657a6f732d73746f726167653a6d ;
0x7368613235363a2f2f3078316637633766646533393162633436613238636439386137373733336662653539323731393064626535343933666538313234346565323964633632343537372f6d617672796b2d73746f726167653a6d ;
Elt "m"
0x7b22617574686f7273223a5b224068696365746e756e6332303030203c68696365746e756e63323030304070726f746f6e6d61696c2e636f6d3e225d2c226465736372697074696f6e223a224f424a4b54732046413220636f6c6c65637469626c6573222c22686f6d6570616765223a2268747470733a2f2f68696365746e756e632e78797a222c22696e7465726661636573223a5b22545a49502d3132225d2c226c6963656e7365223a7b226e616d65223a224d4954227d2c226e616d65223a224f424a4b5473222c227265706f7369746f7279223a2268747470733a2f2f6769746875622e636f6d2f686963326e6332303030222c2276657273696f6e223a22322e302e30227d }) |}];
run_ligo_good
Expand All @@ -358,7 +358,7 @@ let%expect_test _ =
Warning: Hash mismatch in metadata's JSON document: got 1f7c7fde391bc46a28cd98a77733fbe5927190dbe5493fe81244ee29dc624577, when given ff7c7fde391bc46a28cd98a77733fbe5927190dbe5493fe81244ee29dc624577.
(Pair 42
{ Elt ""
0x7368613235363a2f2f3078666637633766646533393162633436613238636439386137373733336662653539323731393064626535343933666538313234346565323964633632343537372f74657a6f732d73746f726167653a6d ;
0x7368613235363a2f2f3078666637633766646533393162633436613238636439386137373733336662653539323731393064626535343933666538313234346565323964633632343537372f6d617672796b2d73746f726167653a6d ;
Elt "m"
0x7b22617574686f7273223a5b224068696365746e756e6332303030203c68696365746e756e63323030304070726f746f6e6d61696c2e636f6d3e225d2c226465736372697074696f6e223a224f424a4b54732046413220636f6c6c65637469626c6573222c22686f6d6570616765223a2268747470733a2f2f68696365746e756e632e78797a222c22696e7465726661636573223a5b22545a49502d3132225d2c226c6963656e7365223a7b226e616d65223a224d4954227d2c226e616d65223a224f424a4b5473222c227265706f7369746f7279223a2268747470733a2f2f6769746875622e636f6d2f686963326e6332303030222c2276657273696f6e223a22322e302e30227d }) |}];
run_ligo_good
Expand All @@ -373,7 +373,8 @@ let%expect_test _ =
{|
Warning: Slash ('/') not in a valid position in URI: "hello/invalid_not_http", use instead "%2F".
(Pair 42
{ Elt "" 0x74657a6f732d73746f726167653a68656c6c6f2f696e76616c69645f6e6f745f68747470 ;
{ Elt ""
0x6d617672796b2d73746f726167653a68656c6c6f2f696e76616c69645f6e6f745f68747470 ;
Elt "hello/world" 0x4a534f4e3f ;
Elt "invalid_not_http" 0x68747470733a2f2f7777772e6578616d706c652e636f6d ;
Elt "invalid_trailing_slash"
Expand Down Expand Up @@ -405,7 +406,7 @@ let%expect_test _ =
{|
Warning: Could not find key haha in storage's metadata.
(Pair 42
{ Elt "" 0x74657a6f732d73746f726167653a68616861 ;
{ Elt "" 0x6d617672796b2d73746f726167653a68616861 ;
Elt "hello/world" 0x687474703a2f2f7777772e6578616d706c652e636f6d }) |}];
run_ligo_good
[ "compile"
Expand All @@ -420,7 +421,8 @@ let%expect_test _ =
Warning: Could not parse JSON in storage's metadata: "Line 1, bytes 0-7:
Invalid token 'nojson!'".
(Pair 42
{ Elt "" 0x74657a6f732d73746f726167653a68616861 ; Elt "haha" 0x6e6f6a736f6e21 }) |}];
{ Elt "" 0x6d617672796b2d73746f726167653a68616861 ;
Elt "haha" 0x6e6f6a736f6e21 }) |}];
run_ligo_good
[ "compile"
; "storage"
Expand All @@ -433,7 +435,7 @@ let%expect_test _ =
{|
Warning: Error in JSON in storage's metadata: could not successfully typecheck the view "get-allowance-for-user" w.r.t. to parameter, returnType and storage of the contract.
(Pair 42
{ Elt "" 0x74657a6f732d73746f726167653a68656c6c6f253246776f726c64 ;
{ Elt "" 0x6d617672796b2d73746f726167653a68656c6c6f253246776f726c64 ;
Elt "hello/world"
0x207b0a2020226e616d65223a22464132204e4654204d61726b6574706c616365222c0a2020226465736372697074696f6e223a224578616d706c65206f662046413220696d706c656d656e746174696f6e222c0a20202276657273696f6e223a22302e302e31222c0a2020226c6963656e7365223a7b226e616d65223a224d4954227d2c0a202022617574686f7273223a5b224d617269676f6c643c636f6e74616374406d617269676f6c642e6465763e225d2c0a202022686f6d6570616765223a2268747470733a2f2f6d617269676f6c642e646576222c0a202022736f75726365223a7b0a202022746f6f6c73223a5b224c69676f225d2c0a2020226c6f636174696f6e223a2268747470733a2f2f6769746875622e636f6d2f6c69676f6c616e672f636f6e74726163742d636174616c6f6775652f747265652f6d61696e2f6c69622f666132227d2c0a202022696e7465726661636573223a5b22545a49502d303132225d2c0a2020226572726f7273223a205b5d2c0a2020227669657773223a205b0a202020207b0a202020202020226e616d65223a20226765742d616c6c6f77616e63652d666f722d75736572222c0a202020202020226465736372697074696f6e223a2022476574207468652063757272656e7420616c6c6f77616e636520666f7220612075736572206f662074686520636f6e74726163742e222c0a2020202020202270757265223a202274727565222c0a20202020202022696d706c656d656e746174696f6e73223a205b0a2020202020202020207b20226d696368656c736f6e53746f726167655669657722203a207b22706172616d65746572223a7b227072696d223a22737472696e67227d2c2272657475726e54797065223a7b227072696d223a22696e74227d2c22636f6465223a5b7b227072696d223a22554e50414952227d2c7b227072696d223a2253574150227d2c7b227072696d223a22434152227d2c7b227072696d223a22414444227d5d7d207d0a20202020202020205d0a202020207d0a202020205d0a20207d0a2020 }) |}]
Expand Down
4 changes: 2 additions & 2 deletions src/bin/expect_tests/package_management.ml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ let%expect_test _ =
[%expect
{|
File "originate_contract/main.mligo", line 1, characters 0-30:
1 | #import "mavryk-ligo-fa2" "FA2"
1 | #import "tezos-ligo-fa2" "FA2"
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2 |
File "mavryk-ligo-fa2" not found. |}]
File "tezos-ligo-fa2" not found. |}]

let () = Caml.Sys.chdir "using_scope_pkg_project"

Expand Down
1 change: 1 addition & 0 deletions src/test/contracts/tutorials/mv-vs-eth/Counter.mligo
1 change: 1 addition & 0 deletions src/test/contracts/tutorials/mv-vs-eth/Lambda.mligo
1 change: 0 additions & 1 deletion src/test/contracts/tutorials/tz-vs-eth/Counter.mligo

This file was deleted.

1 change: 0 additions & 1 deletion src/test/contracts/tutorials/tz-vs-eth/Lambda.mligo

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#import "mavryk-ligo-fa2/lib/fa2/asset/single_asset.mligo" "FA2"
#import "tezos-ligo-fa2/lib/fa2/asset/single_asset.mligo" "FA2"

type t = address

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "mavryk-ligo-fa2",
"name": "tezos-ligo-fa2",
"version": "1.0.4",
"description": "A FA2 contract with nft, single asset & multi asset contracts",
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion src/test/projects/dao_path_bug/_esy/ligo/installation.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"mavryk[email protected]@d41d8cd9":
"tezos[email protected]@d41d8cd9":
"./.ligo/source/i/tezos_ligo_fa2__1.0.4__d08b6a16",
"dao_path_bug@link-dev:./ligo.json":
".",
Expand Down
10 changes: 5 additions & 5 deletions src/test/projects/dao_path_bug/ligo.esy.lock/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
"checksum": "236cd3ef677e0a02655a611bb99e43f0",
"root": "dao_path_bug@link-dev:./ligo.json",
"node": {
"mavryk[email protected]@d41d8cd9": {
"id": "mavryk[email protected]@d41d8cd9",
"name": "mavryk-ligo-fa2",
"tezos[email protected]@d41d8cd9": {
"id": "tezos[email protected]@d41d8cd9",
"name": "tezos-ligo-fa2",
"version": "1.0.4",
"source": {
"type": "install",
"source": [
"archive:https://beta.packages.ligolang.org/-/api/mavryk-ligo-fa2/-/mavryk-ligo-fa2-1.0.4.tgz#sha1:05e8ae8baf69910ad2b498c69fa15e942e613a5e"
"archive:https://beta.packages.ligolang.org/-/api/tezos-ligo-fa2/-/tezos-ligo-fa2-1.0.4.tgz#sha1:05e8ae8baf69910ad2b498c69fa15e942e613a5e"
]
},
"overrides": [],
Expand Down Expand Up @@ -40,7 +40,7 @@
]
},
"overrides": [],
"dependencies": [ "mavryk[email protected]@d41d8cd9" ],
"dependencies": [ "tezos[email protected]@d41d8cd9" ],
"devDependencies": []
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "mavryk-ligo-fa2",
"name": "tezos-ligo-fa2",
"version": "1.0.1",
"description": "A FA2 contract with nft, single asset & multi asset contracts",
"directories": {
Expand Down
10 changes: 5 additions & 5 deletions src/test/projects/originate_contract/ligo.esy.lock/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
"checksum": "0368ea2d83170996ad9738325570fe1a",
"root": "originate_contract@link-dev:./ligo.json",
"node": {
"mavryk[email protected]@d41d8cd9": {
"id": "mavryk[email protected]@d41d8cd9",
"name": "mavryk-ligo-fa2",
"tezos[email protected]@d41d8cd9": {
"id": "tezos[email protected]@d41d8cd9",
"name": "tezos-ligo-fa2",
"version": "1.0.1",
"source": {
"type": "install",
"source": [
"archive:https://registry.npmjs.org/mavryk-ligo-fa2/-/mavryk-ligo-fa2-1.0.1.tgz#sha1:81d1ff74dc457290fcd974e1251c15521e407149"
"archive:https://registry.npmjs.org/tezos-ligo-fa2/-/tezos-ligo-fa2-1.0.1.tgz#sha1:81d1ff74dc457290fcd974e1251c15521e407149"
]
},
"overrides": [],
Expand All @@ -26,7 +26,7 @@
"manifest": "ligo.json"
},
"overrides": [],
"dependencies": [ "mavryk[email protected]@d41d8cd9" ],
"dependencies": [ "tezos[email protected]@d41d8cd9" ],
"devDependencies": []
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/projects/originate_contract/ligo.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "dependencies": { "mavryk-ligo-fa2": "^1.0.1" } }
{ "dependencies": { "tezos-ligo-fa2": "^1.0.1" } }
2 changes: 1 addition & 1 deletion src/test/projects/originate_contract/main.mligo
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#import "mavryk-ligo-fa2" "FA2"
#import "tezos-ligo-fa2" "FA2"

let main (_,_ : unit * unit) : operation list * unit = [], ()
6 changes: 3 additions & 3 deletions src/test/projects/originate_contract/test.mligo
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#import "mavryk-ligo-fa2/lib/fa2/asset/single_asset.mligo" "SingleAsset"
#import "mavryk-ligo-fa2/test/fa2/single_asset.test.mligo" "SingleAsset_helper"
#import "tezos-ligo-fa2/lib/fa2/asset/single_asset.mligo" "SingleAsset"
#import "tezos-ligo-fa2/test/fa2/single_asset.test.mligo" "SingleAsset_helper"

let test =
let f = "mavryk-ligo-fa2/lib/fa2/asset/single_asset.mligo" in
let f = "tezos-ligo-fa2/lib/fa2/asset/single_asset.mligo" in
let init_storage, owners, ops = SingleAsset_helper.get_initial_storage(10n, 10n, 10n) in
let orig : (SingleAsset parameter_of, SingleAsset.storage) origination_result = Test.originate_from_file f init_storage 0mav in
Test.to_contract orig.addr
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ generateDeployScript request = do

let morleyConfig :: MorleyClientConfig
morleyConfig = MorleyClientConfig
{ mccEndpointUrl = Just (BaseUrl Https "rpc.mavryk.network" 443 "/atlasnet")
{ mccEndpointUrl = Just (BaseUrl Https "atlasnet.rpc.mavryk.network" 443 )
, mccMavrykClientPath = mavkitClientPath
, mccMbMavrykClientDataDir = Nothing
, mccVerbosity = 0
Expand Down
6 changes: 3 additions & 3 deletions tools/webide-new/ligo-webide-frontend/ligo-ide/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"group":"Tezos",
"name":"Atlasnet",
"fullName":"Atlasnet Testnet",
"url":"https://rpc.mavryk.network/atlasnet",
"explorerUrl":"https://api.mavryk.network/atlasnet",
"url":"https://atlasnet.rpc.mavryk.network",
"explorerUrl":"https://atlasnet.api.mavryk.network",
"symbol":"MAV",
"icon":"mavrykmain",
"faucetUrl": "https://atlasnet-faucet.mavryk.network/",
"faucetUrl": "https://atlasnet.faucet.mavryk.network",
"type":"atlasnet"
}
]
Expand Down

0 comments on commit 0b07515

Please sign in to comment.