Skip to content

Commit

Permalink
clean and improve as config (#357)
Browse files Browse the repository at this point in the history
  • Loading branch information
Thykof authored Aug 6, 2024
1 parent e30ff40 commit 531b273
Show file tree
Hide file tree
Showing 8 changed files with 134 additions and 1,988 deletions.
4 changes: 4 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
}
30 changes: 10 additions & 20 deletions asconfig.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,13 @@
{
"targets": {
"debug": {
"outFile": "build/debug.wasm",
"textFile": "build/debug.wat",
"sourceMap": true,
"debug": true
},
"release": {
"outFile": "build/release.wasm",
"textFile": "build/release.wat",
"sourceMap": true,
"optimizeLevel": 3,
"shrinkLevel": 0,
"converge": false,
"noAssert": false
"targets": {
"release": {
"sourceMap": true,
"optimizeLevel": 3,
"shrinkLevel": 3,
"converge": true,
"noAssert": false,
"exportRuntime": true,
"bindings": false
}
}
},
"options": {
"bindings": "esm",
"transform": ["@massalabs/as-transformer"]
}
}
3 changes: 0 additions & 3 deletions assembly/__tests__/env-account.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
import { Address } from '../std';
import { changeCallStack, resetStorage } from '../vm-mock/storage';
import { Args, bytesToString, stringToBytes } from '@massalabs/as-types';
import { env } from '../env/index';

describe('Testing mocked account related functions', () => {
Expand Down
4 changes: 2 additions & 2 deletions assembly/__tests__/env-opdatastore.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { env } from '../env/index';

import { changeCallStack, resetStorage } from '../vm-mock/storage';
import { Args, bytesToString, stringToBytes } from '@massalabs/as-types';
import { resetStorage } from '../vm-mock/storage';
import { stringToBytes } from '@massalabs/as-types';

describe('Testing mocked Operation Datastore', () => {
beforeAll(() => {
Expand Down
2 changes: 1 addition & 1 deletion assembly/security/accessControl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ import { Address, Storage } from '../std/index';
* return [];
* }
*
* export function superSensite(_: StaticArray<u8>): StaticArray<u8> {
* export function superSensible(_: StaticArray<u8>): StaticArray<u8> {
* controller.mustHavePermission(ADMIN, Context.caller());
* return stringToBytes('Super sensitive data');
* }
Expand Down
2 changes: 1 addition & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
// export {env};

// massa std functionalities
export * from "./assembly/index";
export * from './assembly/index';
Loading

0 comments on commit 531b273

Please sign in to comment.