Skip to content

Commit

Permalink
added test specific consoling
Browse files Browse the repository at this point in the history
  • Loading branch information
jawndiego committed Nov 29, 2023
1 parent 075e251 commit c224cb5
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ describe('Core Tests', () => {
jest.setTimeout(60000)

// Pre-registration check
console.log("pre-registration check")
try {
const preRegistrationStatus = await entropy.isRegistered(
charlieStashAddress
Expand Down Expand Up @@ -94,6 +95,8 @@ describe('Core Tests', () => {
).toBeTruthy()

// Post-registration check
console.log("post-registration check")

try {
const postRegistrationStatus = await entropy.isRegistered(
charlieStashAddress
Expand All @@ -113,11 +116,14 @@ describe('Core Tests', () => {
}

// Set a program for the user
console.log("setting program")

const dummyProgram: any = readFileSync(
'./tests/testing-utils/template_barebones.wasm'
)
await entropy.programs.set(dummyProgram)
// Retrieve the program and compare
console.log("getting program")
const fetchedProgram: ArrayBuffer = await entropy.programs.get()
const trimmedBuffer = fetchedProgram.slice(1)

Expand All @@ -131,6 +137,9 @@ describe('Core Tests', () => {

const derivedAddress = keypair.address

console.log("not authorized to set program test")


try {
await entropy.programs.set(dummyProgram, derivedAddress)
expect(
Expand Down Expand Up @@ -172,6 +181,8 @@ describe('Core Tests', () => {
expect(wrong_constraint.length).toBe(0)
*/
// signing should work for whitelisted tx requests
console.log("signing test")

const serializedTx = ethers.utils.serializeTransaction(
whitelisted_test_tx_req
)
Expand Down

0 comments on commit c224cb5

Please sign in to comment.