Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: create IVersion interface #19

Merged
merged 16 commits into from
Nov 4, 2024
Merged

feat: create IVersion interface #19

merged 16 commits into from
Nov 4, 2024

Conversation

ihoroleksiienko
Copy link
Contributor

@ihoroleksiienko ihoroleksiienko commented Oct 30, 2024

Main changes

A new IVersion interface has been introduced to provide structured versioning of smart contracts.

/**
 * @title IVersion interface
 * @author CloudWalk Inc. (See https://cloudwalk.io)
 * @dev Defines the function to get the contract version.
 */
interface IVersion {
    /**
     * @dev The struct for the contract version.
     */
    struct Version {
        uint8 major; // -- The major version of contract
        uint8 minor; // -- The minor version of contract
        uint8 patch; // -- The patch version of contract
    }

    /**
     * @dev Returns the version of the contract.
     */
    function $__VERSION() external pure returns (Version memory);
}

Test coverage

New functionality was fully covered by tests.

@ihoroleksiienko ihoroleksiienko marked this pull request as ready for review November 1, 2024 15:43
@igorsenych-cw igorsenych-cw changed the title Feat/add version feat: create $__VERSION function Nov 4, 2024
@igorsenych-cw igorsenych-cw merged commit e379bf8 into main Nov 4, 2024
6 checks passed
@igorsenych-cw igorsenych-cw deleted the feat/add-version branch November 4, 2024 12:51
@igorsenych-cw igorsenych-cw changed the title feat: create $__VERSION function feat: create IVersion interface Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants