Skip to content

Commit

Permalink
updated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
michele-nuzzi committed Jul 13, 2024
1 parent f0f6a69 commit 4b54a0a
Show file tree
Hide file tree
Showing 22 changed files with 177 additions and 3,109 deletions.
1,131 changes: 0 additions & 1,131 deletions packages/offchain/src/__tests__/TxBuilder.build.fee.test.ts

This file was deleted.

4 changes: 2 additions & 2 deletions packages/offchain/src/__tests__/TxBuilder.build.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -327,15 +327,15 @@ describe("TxBuilder.build", () => {
const onlyBigThirdElem = pfn([
data,
list( int ),
PScriptContext.type
V2.PScriptContext.type
], bool)
(( _dat, nums, _ctx ) =>
nums.at(0).ltEq( (BigInt(1) << BigInt(64)) - BigInt(1) )
)
const mintSomething = pfn([
data,
PScriptContext.type
V2.PScriptContext.type
], bool)
(( _rdmr, ctx ) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ describe("build time", () => {
const simpleScript = new Script(
"PlutusScriptV2",
compile(
pfn([ data, data, PScriptContext.type ], unit )( ( d, r, c ) => pmakeUnit() )
pfn([ data, data, V2.PScriptContext.type ], unit )( ( d, r, c ) => pmakeUnit() )
)
);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { PMaybe, PPubKeyHash, PScriptContext, bool, bs, compile, pBool, pfn, plet, pmatch, pstruct, unit } from "../../../pluts"
import { PMaybe, PPubKeyHash, PScriptContext, V2, bool, bs, compile, pBool, pfn, plet, pmatch, pstruct, unit } from "../../../pluts"


describe("compile PMaybe func", () => {
Expand Down Expand Up @@ -40,7 +40,7 @@ describe("compile PMaybe func", () => {
PMaybe( bs ).type,
unit,
unit,
PScriptContext.type
V2.PScriptContext.type
], bool)
( (mbs, a, b, ctx ) => {

Expand All @@ -57,7 +57,7 @@ describe("compile PMaybe func", () => {
PMaybe( bs ).type,
unit,
unit,
PScriptContext.type
V2.PScriptContext.type
], bool)
( (mbs, a, b, ctx ) => {

Expand All @@ -76,7 +76,7 @@ describe("compile PMaybe func", () => {
PMaybe( PPubKeyHash.type ).type,
unit,
unit,
PScriptContext.type
V2.PScriptContext.type
], bool)
( (mbs, a, b, ctx ) => {

Expand Down Expand Up @@ -106,7 +106,7 @@ describe("compile PMaybe func", () => {
PMaybe( PPubKeyHash.type ).type,
FakeDat.type,
unit,
PScriptContext.type
V2.PScriptContext.type
], bool)
( (mbs, dat, b, ctx ) => {

Expand Down Expand Up @@ -142,7 +142,7 @@ describe("compile PMaybe func", () => {
PMaybe( PPubKeyHash.type ).type,
FakeDat.type,
FakeRdmr.type,
PScriptContext.type
V2.PScriptContext.type
], bool)
( (mbs, dat, rdmr, ctx ) => {

Expand Down
1 change: 1 addition & 0 deletions packages/onchain/src/pluts/API/V1/Interval/PExtended.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { palias } from "../../../PTypes/PAlias/palias";
import { pstruct } from "../../../PTypes/PStruct/pstruct";
import { pfn } from "../../../lib/pfn";
import { pInt } from "../../../lib/std/int";
import { int } from "../../../type_system";

Expand Down

This file was deleted.

6 changes: 4 additions & 2 deletions packages/onchain/src/pluts/API/V1/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import { PTxOut } from "./Tx/PTxOut";
import { PTxOutRef } from "./Tx/PTxOutRef";
import { PCurrencySymbol } from "./Value/PCurrencySymbol";
import { PTokenName } from "./Value/PTokenName";
import { PValue } from "./Value/PValue";
import { PAssetsEntry, PValue, PValueEntry } from "./Value/PValue";
import { PBound } from "./Interval/PBound";

export const V1 = Object.freeze({
Expand Down Expand Up @@ -85,5 +85,7 @@ export const V1 = Object.freeze({
// ./Value
PCurrencySymbol,
PTokenName,
PValue
PValue,
PValueEntry,
PAssetsEntry
});
Loading

0 comments on commit 4b54a0a

Please sign in to comment.